diff --git a/app/models/config.py b/app/models/config.py
index 7379398..3d6001a 100644
--- a/app/models/config.py
+++ b/app/models/config.py
@@ -158,14 +158,17 @@ class Config:
self[param_key] = param_val
return self
- def to_params(self) -> str:
+ def to_params(self, keys: list = []) -> str:
"""Generates a set of safe params for using in Whoogle URLs
Returns:
str -- a set of URL parameters
"""
+ if not len(keys):
+ keys = self.safe_keys
+
param_str = ''
- for safe_key in self.safe_keys:
+ for safe_key in keys:
if not self[safe_key]:
continue
param_str = param_str + f'&{safe_key}={self[safe_key]}'
diff --git a/app/routes.py b/app/routes.py
index 381b9ea..c1bb56b 100644
--- a/app/routes.py
+++ b/app/routes.py
@@ -326,7 +326,7 @@ def search():
farside='https://farside.link',
config=g.user_config,
query=urlparse.unquote(query),
- params=g.user_config.to_params()), 503
+ params=g.user_config.to_params(keys=['preferences'])), 503
response = bold_search_terms(response, query)
# Feature to display IP address
diff --git a/app/templates/error.html b/app/templates/error.html
index 708f749..d302270 100644
--- a/app/templates/error.html
+++ b/app/templates/error.html
@@ -25,7 +25,7 @@
Whoogle:
- {{farside}}/whoogle/search?q={{query}}{{params}}
+ {{farside}}/whoogle/search?q={{query}}
Searx: