diff options
Diffstat (limited to 'app/assets/javascripts/protected_branches/protected_branch_create.js')
-rw-r--r-- | app/assets/javascripts/protected_branches/protected_branch_create.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/assets/javascripts/protected_branches/protected_branch_create.js b/app/assets/javascripts/protected_branches/protected_branch_create.js index 16eb5c3de32..120f75d4f0c 100644 --- a/app/assets/javascripts/protected_branches/protected_branch_create.js +++ b/app/assets/javascripts/protected_branches/protected_branch_create.js @@ -1,6 +1,6 @@ import $ from 'jquery'; import CreateItemDropdown from '~/create_item_dropdown'; -import createFlash from '~/flash'; +import { createAlert } from '~/flash'; import AccessorUtilities from '~/lib/utils/accessor'; import axios from '~/lib/utils/axios_utils'; import { __ } from '~/locale'; @@ -74,7 +74,7 @@ export default class ProtectedBranchCreate { $allowedToPush.length ); - this.$form.find('input[type="submit"]').attr('disabled', toggle); + this.$form.find('button[type="submit"]').attr('disabled', toggle); } static getProtectedBranches(term, callback) { @@ -130,7 +130,7 @@ export default class ProtectedBranchCreate { window.location.reload(); }) .catch(() => - createFlash({ + createAlert({ message: __('Failed to protect the branch'), }), ); |