From bf1d00b5f89c222f0a21af700e6021c58313f605 Mon Sep 17 00:00:00 2001 From: Developer <> Date: Thu, 18 Feb 2021 23:18:16 -0500 Subject: [PATCH] Added new follow limit for unconfirmed accounts to 10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit • Added: - new follow limit for unconfirmed accounts to 10 --- app/validators/follow_limit_validator.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/validators/follow_limit_validator.rb b/app/validators/follow_limit_validator.rb index 2acc2b6a..ef32ff61 100644 --- a/app/validators/follow_limit_validator.rb +++ b/app/validators/follow_limit_validator.rb @@ -13,6 +13,7 @@ class FollowLimitValidator < ActiveModel::Validator def limit_for_account(account) adjusted_limit = account.is_pro ? 50000 : LIMIT adjusted_limit = account.is_flagged_as_spam ? 0 : LIMIT + adjusted_limit = !account.user.confirmed? ? 10 : LIMIT if account.following_count < adjusted_limit adjusted_limit