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

Do not respond to every method with suffix #104

Conversation

Maxim-Filimonov
Copy link
Contributor

Resolves #89. Does not break any tests but not sure how does it affect dependent libraries like grape.

@dblock dblock merged commit a21eea9 into hashie:master Mar 30, 2014
@dblock
Copy link
Member

dblock commented Mar 30, 2014

I'm taking over this project, this has been merged. Thanks for contributing!

@7even
Copy link
Contributor

7even commented Apr 29, 2014

If a mash successfully processes methods like #wrong_key_ via method_missing, shouldn't mash.respond_to?(:wrong_key_) return true? This just broke my gem.

7even added a commit to roomink/settings that referenced this pull request Apr 29, 2014
@dblock
Copy link
Member

dblock commented Apr 29, 2014

@7even Yes. Can you please PR a fix/open a bug?

@7even
Copy link
Contributor

7even commented Apr 29, 2014

Well, it was me who initially brought this functionality to hashie, now I'd suggest reverting this pull request (so a mash responds to unknown keys again) and submitting a patch to ActiveModel::ForbiddenAttributesProtection but I'm not sure how to fix the latter.

@dblock
Copy link
Member

dblock commented Apr 29, 2014

Ok, either way open a new issue here re-describing the problem we have now. I'll think about it and we should have other people comment.

@7even
Copy link
Contributor

7even commented Apr 30, 2014

Done.

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 this pull request may close these issues.

Hashie::Mash doesn't play well with Rails and strong_parameters
3 participants