It seems that in rails 3 (version 3.0.7) validates_associated is enabled by default (and as a result it is deprecated).
My model Payment has an associated model Reminder:
class Payment < ActiveRecord::Base
belongs_to :reminder
end
whenever I create a new payment, it also validates the associated reminder. I want to skip this. Adding :validate => false to the relation didn’t work. Any suggestions? And also if someone could tell about the changes in rails 3 w.r.t validates_associated, as I couldn’t find it.
It isn’t a validation issue, but I was updating my Reminder model after creating the Payment entry. That resulted in the validations for Reminder model being triggered.
Added a condition for that special case (where I wanted to skip the validation) to not update the reminder model.
Even though the answer is specific to my scenario, but adding as it may be of help to someone.