summaryrefslogtreecommitdiff
path: root/lib/gitlab/graphql/docs/helper.rb
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-01-24 06:08:51 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-01-24 06:08:51 +0000
commit83a9f472b8b523619519a1834176165c9f1532f7 (patch)
treebc990b78c37c6550ff66b850e731d46322962576 /lib/gitlab/graphql/docs/helper.rb
parent1ce6af4aad0107b6d604f89a3c0b530476a10165 (diff)
downloadgitlab-ce-83a9f472b8b523619519a1834176165c9f1532f7.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/graphql/docs/helper.rb')
-rw-r--r--lib/gitlab/graphql/docs/helper.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/gitlab/graphql/docs/helper.rb b/lib/gitlab/graphql/docs/helper.rb
index ac2a78c0f28..56524120ffd 100644
--- a/lib/gitlab/graphql/docs/helper.rb
+++ b/lib/gitlab/graphql/docs/helper.rb
@@ -21,6 +21,10 @@ module Gitlab
MD
end
+ def sorted_fields(fields)
+ fields.sort_by { |field| field[:name] }
+ end
+
# Some fields types are arrays of other types and are displayed
# on docs wrapped in square brackets, for example: [String!].
# This makes GitLab docs renderer thinks they are links so here