Skip to content
Browse files

Use Class#name instead of Class in belongs_to

  • Loading branch information...
1 parent ce7bac2 commit d9ab4ab9647a7ef5bc84390e3a128506cd00efb7 @ernie ernie committed Sep 3, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/squeel/visitors/predicate_visitor.rb
View
2 lib/squeel/visitors/predicate_visitor.rb
@@ -26,7 +26,7 @@ def expand_belongs_to(o, parent, association)
if association.options[:polymorphic]
conditions << [
context[association.foreign_type].send(
- o.method_name, ar_base.class.base_class
+ o.method_name, ar_base.class.base_class.name
)
]
end

0 comments on commit d9ab4ab

Please sign in to comment.
Something went wrong with that request. Please try again.