Skip to content

fix(ext/node): implement http.res.setHeaders - #30586

Merged
bartlomieju merged 2 commits into
denoland:mainfrom
Tango992:fix-http-setheaders
Sep 1, 2025
Merged

bartlomieju merged 2 commits into
denoland:mainfrom
Tango992:fix-http-setheaders

Conversation

@Tango992

@Tango992 Tango992 commented Sep 1, 2025 •

Copy link
Copy Markdown
Contributor

Closes #30540

Also fixes res.writeHead implementation to parse array values correctly. For example, res.writeHead(200, [["foo", "bar"]]) and res.writeHead(200, ["foo", "bar"]) should produce the same result.

These changes allows parallel/test-http-response-setheaders.js to pass.

@Tango992
Tango992 marked this pull request as draft September 1, 2025 13:55
@Tango992
Tango992 force-pushed the fix-http-setheaders branch from 3570aee to 9ffbb46 Compare September 1, 2025 14:22
@Tango992
Tango992 marked this pull request as ready for review September 1, 2025 14:22

@bartlomieju bartlomieju left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, nice work

@bartlomieju
bartlomieju merged commit 1ef0d08 into denoland:main Sep 1, 2025
@Tango992
Tango992 deleted the fix-http-setheaders branch September 1, 2025 23:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

TypeError: res.setHeaders is not a function

2 participants