diff options
Diffstat (limited to 'lib/api/protected_branches.rb')
-rw-r--r-- | lib/api/protected_branches.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/api/protected_branches.rb b/lib/api/protected_branches.rb index 786045684b8..a50208d78d7 100644 --- a/lib/api/protected_branches.rb +++ b/lib/api/protected_branches.rb @@ -109,13 +109,15 @@ module API failure [ { code: 422, message: 'Push access levels access level has already been taken' }, { code: 404, message: '404 Project Not Found' }, - { code: 401, message: '401 Unauthorized' } + { code: 401, message: '401 Unauthorized' }, + { code: 400, message: '400 Bad request' } ] end params do requires :name, type: String, desc: 'The name of the branch', documentation: { example: 'main' } optional :allow_force_push, type: Boolean, - desc: 'Allow force push for all users with push access.' + desc: 'Allow force push for all users with push access.', + allow_blank: false use :optional_params_ee end |