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 undefined method 'dump' for nil:NilClass (NoMethodError) #1475

Closed
wants to merge 1 commit into from

Conversation

@route
Copy link

@route route commented Nov 8, 2016

As stated in this PR #782 and HTTP RFC https://tools.ietf.org/html/rfc1945#section-6.1 reason phrase is optional in status line, thus @message variable can be nil and error! method can throw error because we try to call dump on nil. I think we can simply avoid this just checking it straightforward.

@hsbt hsbt closed this in 39edad0 Nov 8, 2016
@amatsuda
Copy link
Member

@amatsuda amatsuda commented Nov 8, 2016

@route Thank you!

@route
Copy link
Author

@route route commented Nov 8, 2016

@amatsuda thanks to you!

rhenium pushed a commit to rhenium/ruby that referenced this pull request Nov 21, 2016
Patch by: Dmitry Vorotilin <d.vorotilin@gmail.com> (@route)
Signed-off-by: Akira Matsuda <ronnie@dio.jp>

closes ruby#1475

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56681 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants