diff options
author | Robert Schilling <rschilling@student.tugraz.at> | 2017-08-24 10:41:54 +0200 |
---|---|---|
committer | Robert Schilling <rschilling@student.tugraz.at> | 2017-08-28 17:10:30 +0200 |
commit | dcd4ea473cab20eee05995ecaca043da98ca5a8d (patch) | |
tree | af1c7e0fb076cdc707bae65420419ac671e26b0a /lib/api/protected_branches.rb | |
parent | f0f3f38576c0691e6d0e751c962382beea998afb (diff) | |
download | gitlab-ce-dcd4ea473cab20eee05995ecaca043da98ca5a8d.tar.gz |
Update remaining endpoints
Diffstat (limited to 'lib/api/protected_branches.rb')
-rw-r--r-- | lib/api/protected_branches.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/api/protected_branches.rb b/lib/api/protected_branches.rb index dccf4fa27a7..15fcb9e8e27 100644 --- a/lib/api/protected_branches.rb +++ b/lib/api/protected_branches.rb @@ -76,9 +76,7 @@ module API delete ':id/protected_branches/:name', requirements: BRANCH_ENDPOINT_REQUIREMENTS do protected_branch = user_project.protected_branches.find_by!(name: params[:name]) - protected_branch.destroy - - status 204 + destroy_conditionally!(protected_branch) end end end |