lib/maintain/maintainer.rb in maintain-0.1.8 vs lib/maintain/maintainer.rb in maintain-0.1.9

- old
+ new

@@ -19,10 +19,10 @@ end EOC end # Now define the state if @active_record && method_free?(name, true) - conditions = {:conditions => {@attribute => options.map{|value| states[value]}}} + conditions = {:conditions => {@attribute => options.map{|value| states[value][:value].is_a?(Symbol) ? states[value][:value].to_s : states[value][:value] }}} if defined?(ActiveRecord::VERSION) && ActiveRecord::VERSION::STRING >= "3" maintainee.scope name, conditions else maintainee.named_scope name, conditions end \ No newline at end of file