5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-16 17:36:22 +00:00
panel/app/policies/site_stat_policy.rb

28 lines
378 B
Ruby
Raw Normal View History

2019-08-02 00:20:42 +00:00
# frozen_string_literal: true
# Política de acceso a las estadísticas
class SiteStatPolicy
attr_reader :site_stat, :usuarie
def initialize(usuarie, site_stat)
@usuarie = usuarie
@site_stat = site_stat
end
def index?
site_stat.site.usuarie? usuarie
end
2021-10-08 19:31:02 +00:00
def host?
index?
end
def resources?
index?
end
def uris?
index?
end
2019-08-02 00:20:42 +00:00
end