Get rid of the languages before_save function. It's too shaky
This commit is contained in:
parent
1b9479cb32
commit
be970ba6c0
1 changed files with 0 additions and 5 deletions
|
|
@ -18,7 +18,6 @@ class Person < ActiveRecord::Base
|
||||||
|
|
||||||
before_create :generate_guid
|
before_create :generate_guid
|
||||||
before_save :set_public_name
|
before_save :set_public_name
|
||||||
before_save :languages_upcase
|
|
||||||
|
|
||||||
has_attached_file :avatar,
|
has_attached_file :avatar,
|
||||||
:styles => {:tiny => "16x16>", :small => "32x32>", :large => "128x128>"},
|
:styles => {:tiny => "16x16>", :small => "32x32>", :large => "128x128>"},
|
||||||
|
|
@ -27,10 +26,6 @@ class Person < ActiveRecord::Base
|
||||||
|
|
||||||
alias_attribute :affiliation, :company
|
alias_attribute :affiliation, :company
|
||||||
|
|
||||||
def languages_upcase
|
|
||||||
self.languages = self.languages.upcase if self.languages
|
|
||||||
end
|
|
||||||
|
|
||||||
def to_s
|
def to_s
|
||||||
if self.public_name.empty?
|
if self.public_name.empty?
|
||||||
self.first_name + " " + self.last_name
|
self.first_name + " " + self.last_name
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue