diff options
author | Luke "Jared" Bennett <lbennett@gitlab.com> | 2017-05-03 13:03:57 +0100 |
---|---|---|
committer | Luke "Jared" Bennett <lbennett@gitlab.com> | 2017-05-03 13:03:57 +0100 |
commit | 7788118c3d059ef93bcc49c1b6b6ec7d72faf8b5 (patch) | |
tree | 6642a358083285d90234f8d4ba27d61bfd9448bd /lib/api | |
parent | 637ed8a21e9f9457d1b194f9c591a0813c20cc3e (diff) | |
parent | cac04fbd777ff992bbd92e9ae3cded01d45b07d0 (diff) | |
download | gitlab-ce-7788118c3d059ef93bcc49c1b6b6ec7d72faf8b5.tar.gz |
Merge remote-tracking branch 'origin/master' into add-sentry-js-again-with-vue
Diffstat (limited to 'lib/api')
-rw-r--r-- | lib/api/merge_requests.rb | 2 | ||||
-rw-r--r-- | lib/api/v3/merge_requests.rb | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/lib/api/merge_requests.rb b/lib/api/merge_requests.rb index e5793fbc5cb..710deba5ae3 100644 --- a/lib/api/merge_requests.rb +++ b/lib/api/merge_requests.rb @@ -20,6 +20,8 @@ module API error!(errors[:validate_fork], 422) elsif errors[:validate_branches].any? conflict!(errors[:validate_branches]) + elsif errors[:base].any? + error!(errors[:base], 422) end render_api_error!(errors, 400) diff --git a/lib/api/v3/merge_requests.rb b/lib/api/v3/merge_requests.rb index 3077240e650..1616142a619 100644 --- a/lib/api/v3/merge_requests.rb +++ b/lib/api/v3/merge_requests.rb @@ -23,6 +23,8 @@ module API error!(errors[:validate_fork], 422) elsif errors[:validate_branches].any? conflict!(errors[:validate_branches]) + elsif errors[:base].any? + error!(errors[:base], 422) end render_api_error!(errors, 400) |