Skip to content

Duplicate Header Values are Lost #17

@eternasuno

Description

@eternasuno

The Fetch.Internal.Headers.toHeaders function uses fromFoldable which discards duplicate header names.
I suggest replacing fromFoldable with fromFoldableWith in Fetch.Internal.Headers.toHeaders to preserve all header values, addressing the loss of duplicate header values in the response.

toHeaders :: CoreHeaders.Headers -> Map.Map CaseInsensitiveString String
toHeaders = CoreHeaders.toArray >>> map (lmap CaseInsensitiveString) >>> Map.fromFoldable

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions