accepts_nested_attributes_forでattr_accessorで追加されたattribute だけが変更された場合、UPDATEが走らない。 もちろんbefore_save, after_saveも呼ばれない。 accepts_nested_attributes_forではsave時に ----------------------------------------------- def changed_for_autosave? new_record? || changed? || marked_for_destruction? || nested_records_changed_for_autosave? end ----------------------------------------------- でsaveするか判断してるので ----------------------------------------------- attr_accessor :password def password=(value) @changed_attributes[:password] = value @password = value end ----------------------------------------------- のようにしてやればchanged?がtrueになるのでsaveしてくれる