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

Fix arguments to 404 response #63

Merged
merged 1 commit into from
Dec 9, 2023
Merged

Fix arguments to 404 response #63

merged 1 commit into from
Dec 9, 2023

Conversation

emlove
Copy link
Contributor

@emlove emlove commented Dec 9, 2023

Types of Changes

  • Bug fix.

Contribution

The second argument is the headers field, and it's actually a hash type. Sending an empty array breaks parsing further down the line when trying to look up hash values by key. This change just lets the default argument values be used.

See: https://github.com/rails/rails/blob/c80fa6a0697656a522b7688d116a9a6fca1fc0fd/actionpack/lib/action_dispatch/http/response.rb#L169

Stacktrace:
image

The second argument is the headers field, and it's actually a hash type. Sending an empty array breaks parsing further down the line when trying to look up hash values by key.
Copy link
Member

@ioquatix ioquatix left a comment

Choose a reason for hiding this comment

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

Thanks!

@ioquatix ioquatix self-assigned this Dec 9, 2023
@ioquatix ioquatix added the bug Something isn't working label Dec 9, 2023
@ioquatix ioquatix merged commit 8417b1e into socketry:main Dec 9, 2023
20 of 22 checks passed
@emlove emlove deleted the patch-1 branch December 11, 2023 16:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants