Only save the connected person if it has changed
This commit is contained in:
parent
fc9d9a4c55
commit
2304827569
1 changed files with 1 additions and 1 deletions
|
|
@ -40,7 +40,7 @@ class User < ActiveRecord::Base
|
|||
|
||||
before_destroy :disconnect_everyone, :remove_person
|
||||
before_save do
|
||||
person.save if person
|
||||
person.save if person && person.changed?
|
||||
end
|
||||
|
||||
attr_accessible :getting_started, :password, :password_confirmation, :language, :disable_mail
|
||||
|
|
|
|||
Loading…
Reference in a new issue