about summary refs log tree commit diff
path: root/app/models/follow.rb
diff options
context:
space:
mode:
authorThibG <thib@sitedethib.com>2018-10-05 19:01:44 +0200
committerGitHub <noreply@github.com>2018-10-05 19:01:44 +0200
commit515ce8f4697fe7edfdf14c45575a71164b920db9 (patch)
tree1211e136ba3e886ee8daaa5200babffc42375dd1 /app/models/follow.rb
parenta9e8f98a9d32c57956d41009bd09a1f33310676e (diff)
parent00fcdebed758f031b486ec239fd425fc54a180b3 (diff)
Merge pull request #762 from ThibG/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'app/models/follow.rb')
-rw-r--r--app/models/follow.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/app/models/follow.rb b/app/models/follow.rb
index 714f4e898..7ad56eb78 100644
--- a/app/models/follow.rb
+++ b/app/models/follow.rb
@@ -25,6 +25,7 @@ class Follow < ApplicationRecord
   has_one :notification, as: :activity, dependent: :destroy
 
   validates :account_id, uniqueness: { scope: :target_account_id }
+  validates_with FollowLimitValidator, on: :create
 
   scope :recent, -> { reorder(id: :desc) }