Commit 06ad5d3055afc25a0f3d75aac99540404b05521c
1 parent
abd49391
Exists in
master
and in
27 other branches
rails3: remove unecessary mass assignment
Showing
1 changed file
with
6 additions
and
2 deletions
Show diff stats
app/models/contact_list.rb
... | ... | @@ -16,12 +16,16 @@ class ContactList < ActiveRecord::Base |
16 | 16 | |
17 | 17 | def register_auth_error |
18 | 18 | msg = _('There was an error while authenticating. Did you enter correct login and password?') |
19 | - self.update_attributes(:fetched => true, :error_fetching => msg) | |
19 | + self.fetched = true | |
20 | + self.error_fetching = msg | |
21 | + self.save! | |
20 | 22 | end |
21 | 23 | |
22 | 24 | def register_error |
23 | 25 | msg = _('There was an error while looking for your contact list. Please, try again') |
24 | - self.update_attributes(:fetched => true, :error_fetching => msg) | |
26 | + self.fetched = true | |
27 | + self.error_fetching = msg | |
28 | + self.save! | |
25 | 29 | end |
26 | 30 | |
27 | 31 | end | ... | ... |