From 969c74b8866a49a26aad352eaad967bac58ff0ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexandre=20Lach=C3=A8ze?= Date: Mon, 10 Jul 2017 23:50:59 +0200 Subject: [PATCH] Use es6 string templating --- lib/renderer/content-scripts-injector.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/renderer/content-scripts-injector.js b/lib/renderer/content-scripts-injector.js index 0bb8ca6893c2..7fbe3f5ef02c 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) }