From 32fb50a0c659cb1410f3cc5a86a8d9fcc3d48cc8 Mon Sep 17 00:00:00 2001 From: Kevin R Date: Fri, 20 Nov 2020 23:37:33 +0100 Subject: [PATCH] Fixed redirection bug #739 Added missing protocol on redirection --- core_js/tools.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/core_js/tools.js b/core_js/tools.js index 44c0cf9..1e8f969 100644 --- a/core_js/tools.js +++ b/core_js/tools.js @@ -287,6 +287,11 @@ function decodeURL(url) { rtn = decodeURIComponent(rtn); } + // Required (e.g., to fix https://github.com/ClearURLs/Addon/issues/71) + if(rtn.substr(0, 4) !== 'http') { + rtn = 'http://'+rtn + } + return rtn; }