Remove useless escape characters
This commit is contained in:
+1
-1
@@ -55,7 +55,7 @@ window.getWindowLocationSearch = function(win) {
|
||||
|
||||
// TODO: Move this elsewhere
|
||||
window.getParameterByName = function(name, url) {
|
||||
name = name.replace(/[\[]/, '\\[').replace(/[\]]/, '\\]');
|
||||
name = name.replace(/[[]/, '\\[').replace(/[\]]/, '\\]');
|
||||
const regexS = '[\\?&]' + name + '=([^&#]*)';
|
||||
const regex = new RegExp(regexS, 'i');
|
||||
const results = regex.exec(url || getWindowLocationSearch());
|
||||
|
||||
Reference in New Issue
Block a user