Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorDouglas Barbosa Alexandre <dbalexandre@gmail.com>2019-04-04 21:46:15 +0300
committerDouglas Barbosa Alexandre <dbalexandre@gmail.com>2019-04-04 21:46:15 +0300
commit6d000c9f9cbc65f92ed27ea55a14e5de9b11320d (patch)
tree5bf39716ebd10e4d6001a56d44798f974fd8d613 /app
parent3958b4d358596cbb6198708d997c14dbe13b400a (diff)
parentbeeeede2eed9bd78a5948178e270935fa9d92c51 (diff)
Merge branch '60057-fix-gitlab-schema-keyerror' into 'master'
Fix a KeyError in GitlabSchema Closes #60057 See merge request gitlab-org/gitlab-ce!27011
Diffstat (limited to 'app')
-rw-r--r--app/graphql/gitlab_schema.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/graphql/gitlab_schema.rb b/app/graphql/gitlab_schema.rb
index 7e3c09440a2..53efd9042b1 100644
--- a/app/graphql/gitlab_schema.rb
+++ b/app/graphql/gitlab_schema.rb
@@ -31,7 +31,7 @@ class GitlabSchema < GraphQL::Schema
end
def self.max_query_complexity(ctx)
- current_user = ctx&.fetch(:current_user)
+ current_user = ctx&.fetch(:current_user, nil)
if current_user&.admin
ADMIN_COMPLEXITY