Commit bb02065a authored by Alfredo Sumaran's avatar Alfredo Sumaran

Prevent setting HTML directly from the JS

parent 1983eb6c
...@@ -66,8 +66,8 @@ class ProtectedBranchDropdown { ...@@ -66,8 +66,8 @@ class ProtectedBranchDropdown {
if (branchName) { if (branchName) {
this.$dropdownContainer this.$dropdownContainer
.find('.create-new-protected-branch') .find('.create-new-protected-branch code')
.html(`Create wildcard <code>${branchName}</code>`); .text(branchName);
} }
this.$dropdownFooter.toggleClass('hidden', !branchName); this.$dropdownFooter.toggleClass('hidden', !branchName);
......
...@@ -11,4 +11,5 @@ ...@@ -11,4 +11,5 @@
%ul.dropdown-footer-list %ul.dropdown-footer-list
%li %li
= link_to '#', title: "New Protected Branch", class: "create-new-protected-branch" do = link_to '#', title: "New Protected Branch", class: "create-new-protected-branch" do
Create new Create wildcard
%code
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment