Method destructs parameter, unconditionally authorizing the next rule #531

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
2 participants
Contributor

steerio commented Dec 15, 2011

Rule#nested_subject_matches_conditions? uses shift on its subject_hash parameter, destroying it. As this hash contains one element (the hash format is merely syntactic sugar in calls to can?), the next rule will get an empty hash, causing it to always return true.

I replaced it with first.

jeremyf closed this May 11, 2012

Collaborator

jeremyf commented May 11, 2012

[Verified] The tests pass, but it appears this is already in master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment