diff options
author | Rémy Coutable <remy@rymai.me> | 2016-07-18 11:16:56 +0300 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2016-07-18 11:16:56 +0300 |
commit | 2cf7f09b1e9ccb000433374a42bd7b33b73f8116 (patch) | |
tree | 743e4ed2a6f2739541891749a6ef31bfd09e6805 /app/assets/javascripts | |
parent | 1266e2664e7b080b440f5fc004424418284ee87b (diff) |
Revert "Revert "Merge branch '18193-developers-can-merge' into 'master'
""
This reverts commit 530f5158e297f3cde27f3566cfe13bad74ba3b50.
See !4892.
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'app/assets/javascripts')
-rw-r--r-- | app/assets/javascripts/protected_branches.js.coffee | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/app/assets/javascripts/protected_branches.js.coffee b/app/assets/javascripts/protected_branches.js.coffee index 79c2306e4d2..14afef2e2ee 100644 --- a/app/assets/javascripts/protected_branches.js.coffee +++ b/app/assets/javascripts/protected_branches.js.coffee @@ -1,18 +1,18 @@ $ -> $(".protected-branches-list :checkbox").change (e) -> name = $(this).attr("name") - if name == "developers_can_push" + if name == "developers_can_push" || name == "developers_can_merge" id = $(this).val() - checked = $(this).is(":checked") + can_push = $(this).is(":checked") url = $(this).data("url") $.ajax - type: "PUT" + type: "PATCH" url: url dataType: "json" data: id: id protected_branch: - developers_can_push: checked + "#{name}": can_push success: -> row = $(e.target) |