]> git.ipfire.org Git - thirdparty/bootstrap.git/commit
Adjust regex `SAFE_URL_PATTERN` for use with test method of regexes. (#33136)
authorNikon the Third <christian.berrer@gmail.com>
Fri, 19 Feb 2021 08:24:53 +0000 (09:24 +0100)
committerGitHub <noreply@github.com>
Fri, 19 Feb 2021 08:24:53 +0000 (10:24 +0200)
commite8f08d1802976b8200551de49354757f84e438cf
tree9b93206a442b98c147c1820179f8232bc7e565b6
parent454d8ae1f4513109abeb5b82a015691be5e95f0b
Adjust regex `SAFE_URL_PATTERN` for use with test method of regexes. (#33136)

The test method on regexes behaves different than the match method on strings in the presence of the global modifier.
Add a unit test for sanitizing the same template twice.

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
js/src/util/sanitizer.js
js/tests/unit/util/sanitizer.spec.js