diff --git a/background.js b/background.js
index 8c34be0476d919cdf613cd45ad0d116aedb28b12..b9b3192cd128cb8ca7a72dd7103b30b3f17f4072 100644
--- a/background.js
+++ b/background.js
@@ -334,7 +334,7 @@ function notify(message) {
 * Make it "blocking" so we can modify the headers.
 */
 function addListener() {
-  let target = config.target_page.replace(' ',''); 
+  let target = config.target_page.replaceAll(' ',''); 
   if ((target === "*") || (target === "")) target = "<all_urls>";
 
   // need to had "extraHeaders" option for chrome https://developer.chrome.com/extensions/webRequest#life_cycle_footnote