summaryrefslogtreecommitdiff
path: root/searx/webapp.py
diff options
context:
space:
mode:
authorMarkus Heiser <markus.heiser@darmarit.de>2020-03-25 11:49:33 +0100
committerMarkus Heiser <markus.heiser@darmarit.de>2020-03-25 11:49:33 +0100
commit04c687403e21f883f9614e6a24df9ec450cfc111 (patch)
tree716ead4c08367dc7b872f5d5e10103ff6c039481 /searx/webapp.py
parent9a2f26d915ee05d933a18c31bca2121658aa7ffd (diff)
[fix] brands: add variables from build env to jinja templating
We have some variables in the build environment which are also needed in the templating process. Theses variables are relavant if one creates a fork with its own branding. We treat these variables under the term 'brands'. Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'searx/webapp.py')
-rwxr-xr-x[-rw-r--r--]searx/webapp.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/searx/webapp.py b/searx/webapp.py
index b3928921e..c6b52d6ab 100644..100755
--- a/searx/webapp.py
+++ b/searx/webapp.py
@@ -57,6 +57,7 @@ from babel.support import Translations
import flask_babel
from flask_babel import Babel, gettext, format_date, format_decimal
from flask.json import jsonify
+from searx import brand
from searx import settings, searx_dir, searx_debug
from searx.exceptions import SearxParameterException
from searx.engines import (
@@ -427,6 +428,8 @@ def render(template_name, override_theme=None, **kwargs):
kwargs['preferences'] = request.preferences
+ kwargs['brand'] = brand
+
kwargs['scripts'] = set()
for plugin in request.user_plugins:
for script in plugin.js_dependencies: