Fix new user bug

This commit is contained in:
Matt Barringer 2013-01-15 13:42:39 +01:00
parent 2f8099b7f5
commit 12b56a436a

View file

@ -59,7 +59,7 @@ class Person < ActiveRecord::Base
private
def biography_limit
if self.biography.split.size > 150
if !self.biography.nil? && self.biography.split.size > 150
errors.add(:abstract, "cannot have more than 150 words")
end
end