activerecord-hackery/squeel — pull request #338 by dontfidget (2014-09-10 05:23:08+00:00)
Title: broken hash conditions

Not really a pull request, just a test. Seems like squeel breaks the following expressions:

```ruby
Comment.joins(:article).where(articles: {person_id: person})
Comment.joins(:article).where(articles: {person: person})
````

These will both raise an exception telling us that 'articles' cannot be converted to a class.

The fix looks like it would be pretty involved. Essentially squeel is trying to replicate AR predicate builder, but it might be better offer using it, and somehow converting the resulting arel back into something it can work with because trying to keep the behavior up to date and matching might be a pain.