mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Merge pull request #2905 from techAPJ/patch-3
FIX: disposable invite was giving email validation error
This commit is contained in:
commit
e341fe9701
@ -10,7 +10,7 @@ class EmailValidator < ActiveModel::EachValidator
|
||||
record.errors.add(attribute, I18n.t(:'user.email.not_allowed'))
|
||||
end
|
||||
end
|
||||
if record.errors[attribute].blank? and ScreenedEmail.should_block?(value)
|
||||
if record.errors[attribute].blank? && value && ScreenedEmail.should_block?(value)
|
||||
record.errors.add(attribute, I18n.t(:'user.email.blocked'))
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user