summaryrefslogtreecommitdiff
path: root/searx/preferences.py
diff options
context:
space:
mode:
authormarc <a01200356@itesm.mx>2017-03-01 17:11:51 -0600
committerAdam Tauber <asciimoo@gmail.com>2017-03-18 23:44:21 +0100
commitfd65c1292179fb082e965a1ee6a88b9298a54fc1 (patch)
treebd2cc7302a1b7d81f2294aab1ad1de0aedd0bdd8 /searx/preferences.py
parent805fb02ed1fb7f8e006c8def7d76a0d1958364bf (diff)
downloadsearxng-fd65c1292179fb082e965a1ee6a88b9298a54fc1.tar.gz
searxng-fd65c1292179fb082e965a1ee6a88b9298a54fc1.zip
make search language handling less strict
languages.py can change, so users may query on a language that is not on the list anymore, even if it is still recognized by a few engines. also made no and nb the same because they seem to return the same, though most engines will only support one or the other.
Diffstat (limited to 'searx/preferences.py')
-rw-r--r--searx/preferences.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/searx/preferences.py b/searx/preferences.py
index 719492460..43d9ec0dd 100644
--- a/searx/preferences.py
+++ b/searx/preferences.py
@@ -107,6 +107,8 @@ class SearchLanguageSetting(EnumStringSetting):
pass
elif lang in self.choices:
data = lang
+ elif data == 'nb-NO':
+ data = 'no-NO'
elif data == 'ar-XA':
data = 'ar-SA'
else: