Does disable_ferret monkey with callbacks at all? I have a model in my
application that has associated models which perform callbacks after
their validation (they're all instantiated around the same time). I
recently added a conditional call to disable ferret provided a flag and
I'm finding these callbacks aren't quite working right.
Here's a code sample:
class Model < ActiveRecord::Base
has_one :associated_model # This model will fill in some fields upon
it's own validation
def save_with_activation_handling!
if active? # This part works
self.activated_at = Time.now
else
disable_ferret :once
self.activated_at = nil
end
save_without_activation_handling!
end
alias_method_chain :save!, :activation_handling
end
Any ideas?
Thank you,
James Herdman
--
Posted via http://www.ruby-forum.com/.
_______________________________________________
Ferret-talk mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/ferret-talk