summaryrefslogtreecommitdiff
path: root/app/controllers
diff options
context:
space:
mode:
authorAlex Kalderimis <alex.kalderimis@gmail.com>2019-07-29 14:36:35 -0400
committerAlex Kalderimis <alex.kalderimis@gmail.com>2019-07-30 11:12:24 -0400
commit8a1fc36e1d3df359c7ab87a5d3b40cf35b2a8604 (patch)
tree052073f9f606a4534f4e1b9c361d74cab5fd569b /app/controllers
parentab509c78929d9b5f4e02d013e8911ac9d0a07aad (diff)
downloadgitlab-ce-8a1fc36e1d3df359c7ab87a5d3b40cf35b2a8604.tar.gz
Propagate argument errors as execution errorsajk-handle-gql-errors
Diffstat (limited to 'app/controllers')
-rw-r--r--app/controllers/graphql_controller.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/controllers/graphql_controller.rb b/app/controllers/graphql_controller.rb
index 9fbbe373b0d..72d40f709e6 100644
--- a/app/controllers/graphql_controller.rb
+++ b/app/controllers/graphql_controller.rb
@@ -30,6 +30,10 @@ class GraphqlController < ApplicationController
render_error(exception.message, status: :unprocessable_entity)
end
+ rescue_from Gitlab::Graphql::Errors::ArgumentError do |exception|
+ render_error(exception.message, status: :unprocessable_entity)
+ end
+
private
def execute_multiplex