From e7f3b7d1c1c1c09b119e3de6796f0bfb39b3e1ae Mon Sep 17 00:00:00 2001 From: ManeraKai Date: Thu, 8 Dec 2022 11:59:06 +0300 Subject: [PATCH] Keeping the other url parameters in Search redirections https://github.com/libredirect/libredirect/issues/523 --- src/assets/javascripts/services.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/assets/javascripts/services.js b/src/assets/javascripts/services.js index 5463bfc..0f92d93 100644 --- a/src/assets/javascripts/services.js +++ b/src/assets/javascripts/services.js @@ -138,11 +138,11 @@ function redirect(url, type, initiator, forceRedirection) { else return `${randomInstance}${url.pathname}/` case "searx": case "searxng": - return `${randomInstance}/?q=${encodeURIComponent(url.searchParams.get("q"))}` + return `${randomInstance}/${url.search}` case "whoogle": - return `${randomInstance}/search?q=${encodeURIComponent(url.searchParams.get("q"))}` + return `${randomInstance}/search${url.search}` case "librex": - return `${randomInstance}/search.php?q=${encodeURIComponent(url.searchParams.get("q"))}` + return `${randomInstance}/search.php${url.search}` case "send": return randomInstance case "nitter":