diff options
Diffstat (limited to 'app/policies/clusters/agent_token_policy.rb')
-rw-r--r-- | app/policies/clusters/agent_token_policy.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/app/policies/clusters/agent_token_policy.rb b/app/policies/clusters/agent_token_policy.rb new file mode 100644 index 00000000000..e876ecfac26 --- /dev/null +++ b/app/policies/clusters/agent_token_policy.rb @@ -0,0 +1,9 @@ +# frozen_string_literal: true + +module Clusters + class AgentTokenPolicy < BasePolicy + alias_method :token, :subject + + delegate { token.agent } + end +end |