summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2016-07-16 11:52:20 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2016-07-16 11:52:20 +0000
commitd3ff86b1eb320474c7321164a5567637dde41184 (patch)
treee627368337df38d8243abed78d9caec8f233df3f
parentc4b4b8a71e21af1fc75ad284453df6be93326d32 (diff)
downloadredmine-d3ff86b1eb320474c7321164a5567637dde41184.tar.gz
redmine-d3ff86b1eb320474c7321164a5567637dde41184.zip
Don't use add_on_empty.
git-svn-id: http://svn.redmine.org/redmine/trunk@15684 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r--app/models/member.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/member.rb b/app/models/member.rb
index 0c6a8868e..6e7cf258b 100644
--- a/app/models/member.rb
+++ b/app/models/member.rb
@@ -193,6 +193,6 @@ class Member < ActiveRecord::Base
protected
def validate_role
- errors.add_on_empty :role if member_roles.empty? && roles.empty?
+ errors.add(:role, :empty) if member_roles.empty? && roles.empty?
end
end