diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2022-08-27 20:56:47 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-27 20:56:47 +0200 |
commit | b399d79545e5e5430cb9d6a2c936efc244b69a75 (patch) | |
tree | 8a94c88f64223803aa1d9ea5bf15437229122dbe /app/models | |
parent | ff19dad5a05dba689122b0427886c8375491571a (diff) |
Add admin API for managing IP blocks (#19065)
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/ip_block.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/models/ip_block.rb b/app/models/ip_block.rb index f40c8a0b1..8666f4248 100644 --- a/app/models/ip_block.rb +++ b/app/models/ip_block.rb @@ -16,6 +16,7 @@ class IpBlock < ApplicationRecord CACHE_KEY = 'blocked_ips' include Expireable + include Paginable enum severity: { sign_up_requires_approval: 5000, @@ -28,7 +29,7 @@ class IpBlock < ApplicationRecord after_commit :reset_cache def to_log_human_identifier - "#{record.ip}/#{record.ip.prefix}" + "#{ip}/#{ip.prefix}" end class << self |