Skip to content

Fix bug with response header creation#892

Merged
fabianfett merged 2 commits intoswift-server:ff-new-http-client-apifrom
xbhatnag:fix-header-bug
Feb 25, 2026
Merged

Fix bug with response header creation#892
fabianfett merged 2 commits intoswift-server:ff-new-http-client-apifrom
xbhatnag:fix-header-bug

Conversation

@xbhatnag
Copy link

When converting the AHC headers to the HTTP API compatible headers, headers with the same name and different values should be inserted instead of being replaced.

Doing responseFields[name] = value would cause a replacement instead of adding a new header.

We want responseFields.append(field) instead.

This change now allows AHC to pass some header conformance tests.

When converting the AHC headers to the HTTP API compatible headers, headers with the same name and different values should be inserted instead of being replaced. This change now allows AHC to pass some header conformance tests.
@fabianfett fabianfett added the semver/none No version bump required. label Feb 25, 2026
@fabianfett fabianfett merged commit 58d9e21 into swift-server:ff-new-http-client-api Feb 25, 2026
30 of 32 checks passed
@xbhatnag xbhatnag deleted the fix-header-bug branch February 25, 2026 18:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

semver/none No version bump required.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants