debian-mirror-gitlab/app/graphql/resolvers/clusters/agent_tokens_resolver.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

18 lines
383 B
Ruby
Raw Normal View History

2021-11-18 22:05:49 +05:30
# frozen_string_literal: true
module Resolvers
module Clusters
class AgentTokensResolver < BaseResolver
type Types::Clusters::AgentTokenType, null: true
alias_method :agent, :object
delegate :project, to: :agent
2023-07-09 08:55:56 +05:30
def resolve(**_args)
::Clusters::AgentTokensFinder.new(agent, current_user, status: :active).execute
2021-11-18 22:05:49 +05:30
end
end
end
end