lib/remarkable/mongoid/associations.rb in remarkable_mongoid-0.1.3 vs lib/remarkable/mongoid/associations.rb in remarkable_mongoid-0.1.4

- old
+ new

@@ -31,12 +31,12 @@ self.attr = attr.to_s self.association_type = association_type end def matches?(subject) - @subject = subject - a = @subject.associations.select { |k,v| v.association == association_type } - a.detect { |k| k.first == attr } != nil + @subject = subject + associations = @subject.associations.select { |k,v| v.association == association_type } + associations.detect { |k| k.first == attr } != nil end def description "has #{humanized_association} association :#{attr}" end \ No newline at end of file