about summary refs log tree commit diff
path: root/app/models/user.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2017-06-09 19:46:01 +0200
committerGitHub <noreply@github.com>2017-06-09 19:46:01 +0200
commitcdff1da901c5e649f75f9fe89e5cf17b591f049e (patch)
tree50472779a91e2adef53fbe006e6224f51a1baf53 /app/models/user.rb
parent1a065fb146752367ed9f9b75973ed9331879e437 (diff)
Correct validators so that existing error messages would look correct (#3668)
Diffstat (limited to 'app/models/user.rb')
-rw-r--r--app/models/user.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/user.rb b/app/models/user.rb
index 0fd3983b4..ca11f2f5d 100644
--- a/app/models/user.rb
+++ b/app/models/user.rb
@@ -47,7 +47,7 @@ class User < ApplicationRecord
   accepts_nested_attributes_for :account
 
   validates :locale, inclusion: I18n.available_locales.map(&:to_s), if: :locale?
-  validates :email, email: true, if: :email_changed?
+  validates_with BlacklistedEmailValidator, if: :email_changed?
 
   scope :recent,    -> { order(id: :desc) }
   scope :admins,    -> { where(admin: true) }