From 8b573c94895dc0ac0e1d9d59cf3e8745e8b539ca Mon Sep 17 00:00:00 2001 From: GitLab Bot Date: Thu, 17 Dec 2020 11:59:07 +0000 Subject: Add latest changes from gitlab-org/gitlab@13-7-stable-ee --- app/graphql/types/ci/detailed_status_type.rb | 30 +++++++++++++++------------- 1 file changed, 16 insertions(+), 14 deletions(-) (limited to 'app/graphql/types/ci/detailed_status_type.rb') diff --git a/app/graphql/types/ci/detailed_status_type.rb b/app/graphql/types/ci/detailed_status_type.rb index 6d8af400ac4..80d73e9b174 100644 --- a/app/graphql/types/ci/detailed_status_type.rb +++ b/app/graphql/types/ci/detailed_status_type.rb @@ -25,20 +25,22 @@ module Types description: 'Tooltip associated with the status', method: :status_tooltip field :action, Types::Ci::StatusActionType, null: true, - description: 'Action information for the status. This includes method, button title, icon, path, and title', - resolve: -> (obj, _args, _ctx) { - if obj.has_action? - { - button_title: obj.action_button_title, - icon: obj.action_icon, - method: obj.action_method, - path: obj.action_path, - title: obj.action_title - } - else - nil - end - } + calls_gitaly: true, + description: 'Action information for the status. This includes method, button title, icon, path, and title' + + def action + if object.has_action? + { + button_title: object.action_button_title, + icon: object.action_icon, + method: object.action_method, + path: object.action_path, + title: object.action_title + } + else + nil + end + end end # rubocop: enable Graphql/AuthorizeTypes end -- cgit v1.2.3