diff --git a/lib/renderer/content-scripts-injector.js b/lib/renderer/content-scripts-injector.js index 0bb8ca6893..7fbe3f5ef0 100644 --- a/lib/renderer/content-scripts-injector.js +++ b/lib/renderer/content-scripts-injector.js @@ -6,7 +6,7 @@ const {runInThisContext} = require('vm') const matchesPattern = function (pattern) { if (pattern === '') return true const regexp = new RegExp('^' + pattern.replace(/\*/g, '.*') + '$') - const url = location.protocol + '//' + location.host + location.pathname + const url = `${location.protocol}//${location.host}${location.pathname}` return url.match(regexp) }