Fixed codeclimate issues

This commit is contained in:
Sergei Tsoganov 2023-07-04 11:36:26 +03:00
parent 97c11f5dfd
commit 537315a8a9
2 changed files with 3 additions and 3 deletions

View file

@ -17,13 +17,13 @@ module WhiteIp::WhiteIpConcern
end
def select_ipv4(ip)
return [] unless check_ip4(ip).present?
return [] if check_ip4(ip).blank?
select { |white_ip| check_ip4(white_ip.ipv4) == check_ip4(ip) }
end
def select_ipv6(ip)
return [] unless check_ip6(ip).present?
return [] if check_ip6(ip).blank?
select { |white_ip| check_ip6(white_ip.ipv6) == check_ip6(ip) }
end

View file

@ -82,7 +82,7 @@ class WhiteIp < ApplicationRecord
ipv4, ipv6,
interfaces.join(', ').upcase,
created_at,
updated_at,
updated_at
]
end