Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fetch.Error has unique headers #18

Closed
glossd opened this issue Nov 13, 2024 · 1 comment · Fixed by #19
Closed

fetch.Error has unique headers #18

glossd opened this issue Nov 13, 2024 · 1 comment · Fixed by #19

Comments

@glossd
Copy link
Owner

glossd commented Nov 13, 2024

Headers according to HTTP 1.1 don't have to be unique and can be repeated.
fetch.Error.Headers filters them out and takes the last one.
fetch.Response handles it with DuplicateHeaders field and Headers() method.
fetch.Error should handle it in the same, but it would break backward compatibility.

@glossd
Copy link
Owner Author

glossd commented Nov 13, 2024

Actually, I don't like Headers() method. It's nicer if it's a field. If I'm breaking backward compatibility then, I should go for the nice one everywhere.

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 a pull request may close this issue.

1 participant