diff options
author | Martin Fischer <martin@push-f.com> | 2022-01-04 18:00:45 +0100 |
---|---|---|
committer | Martin Fischer <martin@push-f.com> | 2022-01-05 11:03:44 +0100 |
commit | a4c2cfb837a3f92e2c0f0b8a0bac7a6e03499640 (patch) | |
tree | c522af821c7584896998ebc74569e9a534fc5ef5 /searx/preferences.py | |
parent | b38036d519c8b74d7be972e7b730b50f92fa8db4 (diff) | |
download | searxng-a4c2cfb837a3f92e2c0f0b8a0bac7a6e03499640.tar.gz searxng-a4c2cfb837a3f92e2c0f0b8a0bac7a6e03499640.zip |
[enh] change categories_as_tabs from a list to a dict
The tab icon names are currently hard coded in the templates.
This commit lets us introduce an icon property in the future, e.g:
categories_as_tabs:
general:
icon: search-outline
Diffstat (limited to 'searx/preferences.py')
-rw-r--r-- | searx/preferences.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/searx/preferences.py b/searx/preferences.py index 918a7a300..b550e1ebd 100644 --- a/searx/preferences.py +++ b/searx/preferences.py @@ -272,7 +272,7 @@ class EnginesSetting(SwitchableSetting): transformed_choices = [] for engine_name, engine in self.choices.items(): # pylint: disable=no-member,access-member-before-definition for category in engine.categories: - if not category in settings['categories_as_tabs'] + [OTHER_CATEGORY]: + if not category in list(settings['categories_as_tabs'].keys()) + [OTHER_CATEGORY]: continue transformed_choice = {} transformed_choice['default_on'] = not engine.disabled |