about summary refs log tree commit diff stats
path: root/src/pages/background/background.js
diff options
context:
space:
mode:
authorManeraKai <manerakai@protonmail.com>2023-03-26 10:31:42 +0300
committerManeraKai <manerakai@protonmail.com>2023-03-26 10:31:42 +0300
commit43fb8406a38ff5b3426d6fe91a6da81f2f41bda6 (patch)
tree2820ec5a0ad2be5d256894c8ce20b668b427f67b /src/pages/background/background.js
parentFixed github typo: https://github.com/libredirect/libredirect/issues/664 (diff)
downloadlibredirect-43fb8406a38ff5b3426d6fe91a6da81f2f41bda6.zip
Fixed LibRedirect breaking reuqests https://github.com/libredirect/libredirect/issues/669
Diffstat (limited to 'src/pages/background/background.js')
-rw-r--r--src/pages/background/background.js6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/pages/background/background.js b/src/pages/background/background.js
index e1230c37..e4fc2f72 100644
--- a/src/pages/background/background.js
+++ b/src/pages/background/background.js
@@ -216,11 +216,7 @@ browser.contextMenus.onClicked.addListener(async (info) => {
 })
 
 browser.webRequest.onHeadersReceived.addListener(
-	e => {
-		let response = servicesHelper.modifyContentSecurityPolicy(e)
-		if (!response) response = servicesHelper.modifyContentSecurityPolicy(e)
-		return response
-	},
+	servicesHelper.modifyContentSecurityPolicy,
 	{ urls: ["<all_urls>"] },
 	["blocking", "responseHeaders"]
 )