diff options
author | Lin Jen-Shin <godfat@godfat.org> | 2017-11-21 23:15:24 +0800 |
---|---|---|
committer | Lin Jen-Shin <godfat@godfat.org> | 2017-11-22 00:59:38 +0800 |
commit | 45568bed36095db0df94cf89a8a04458f56f33dc (patch) | |
tree | c6655290f3fbf1342650b934cdaf7de65326260a /app | |
parent | ffec300b9495f0fe022e777c889407433217497e (diff) | |
download | gitlab-ce-45568bed36095db0df94cf89a8a04458f56f33dc.tar.gz |
Updates based on feedback
Diffstat (limited to 'app')
-rw-r--r-- | app/models/concerns/spammable.rb | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/app/models/concerns/spammable.rb b/app/models/concerns/spammable.rb index 8b56894ec3a..5e4274619c4 100644 --- a/app/models/concerns/spammable.rb +++ b/app/models/concerns/spammable.rb @@ -12,6 +12,7 @@ module Spammable attr_accessor :spam attr_accessor :spam_log + alias_method :spam?, :spam after_validation :check_for_spam, on: [:create, :update] @@ -34,10 +35,6 @@ module Spammable end end - def spam? - spam - end - def check_for_spam error_msg = if Gitlab::Recaptcha.enabled? "Your #{spammable_entity_type} has been recognized as spam. "\ |