Skip to content

Conversation

@hubert
Copy link
Contributor

@hubert hubert commented Mar 13, 2015

As written currently, we are calling to_s on an array of data's keys then checking whether the @_her_root_element is part of the string. I'm betting that the intention is to call to_s on the individual key and then check whether the root element is included in the stringified array of keys.

There are some incidental side effects

  • if the root element is nil, root_element_included always returns true.
  • if the root element is 'foo' and there is an key in the data hash 'foobar', root_element_included? will return true.

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.

1 participant