ip addresses: fix reference to CurrentUser inside visible.

This commit is contained in:
evazion
2020-03-21 22:47:48 -05:00
parent 94aff2c777
commit 92e4635af8

View File

@@ -8,7 +8,7 @@ class IpAddress < ApplicationRecord
end
def self.visible(user)
CurrentUser.is_admin? ? all : where.not(model_type: "Dmail")
user.is_admin? ? all : where.not(model_type: "Dmail")
end
def self.search(params)