rails/rails — pull request #10473 by schuetzm (2013-05-05 14:36:06+00:00)
Title: Don't use self.class in ActiveRecord#sanitize_sql_hash_for_conditions.

`self` is already a class here, so don't call `class` on it again, otherwise
the `PredicateBuilder` will call the non-existant `Class#reflect_on_association`.
This makes Cancan's `accessible_by` useable with multiple rules involving
polymorphic relations.