-
Notifications
You must be signed in to change notification settings - Fork 976
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
allow private parse method in response middleware #1123
allow private parse method in response middleware #1123
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Although I'm not entirely sure as why someone would want to define the parse
method as private, I have nothing against it in principle, so happy to merge this in.
I do, however, not entirely like the unnecessary line I commented on below, and would prefer to take it out before merging.
change as you required. Let me know if you have anything else that does not convince you. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All changes implemented, tests pass!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for applying the change! Looks good now 🙌
LGTM
Description
Currently the Response Middleware enforces children classes to define public
parse
method.This is due to the implicit arg
all_included=false
passed to respond_to? methodNow I would like to allow also private and protected
parse
method to allow more flexibility for the children classes.Todos
List any remaining work that needs to be done, i.e:
Additional Notes
When running
bundle exec rspec
on master i noticed a bounce of failing specs which are not depending on this PR code changes.The error is:
and it refers to lib/faraday/adapter/rack.rb:62
Maybe an issue to fix that should be open.