diff options
| author | Adam Tauber <asciimoo@gmail.com> | 2016-12-28 20:09:57 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-12-28 20:09:57 +0100 |
| commit | 9743bde25ef2ce6b765b8192aafcdc0a15739b17 (patch) | |
| tree | 00fd6b0b14773c0e20425d4a6478d67f244d64ed /searx/engines/archlinux.py | |
| parent | ea034fafa994227ea89662710901e73cb901e28c (diff) | |
| parent | 8bff42f049dcac77559beaf2932a47921feb1d49 (diff) | |
Merge pull request #748 from a01200356/languages
[mod] Allow users to search in most engine supported languages
Diffstat (limited to 'searx/engines/archlinux.py')
| -rw-r--r-- | searx/engines/archlinux.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/searx/engines/archlinux.py b/searx/engines/archlinux.py index 5ba512766..dca825790 100644 --- a/searx/engines/archlinux.py +++ b/searx/engines/archlinux.py @@ -29,8 +29,8 @@ xpath_link = './/div[@class="mw-search-result-heading"]/a' # cut 'en' from 'en_US', 'de' from 'de_CH', and so on def locale_to_lang_code(locale): - if locale.find('_') >= 0: - locale = locale.split('_')[0] + if locale.find('-') >= 0: + locale = locale.split('-')[0] return locale @@ -95,6 +95,7 @@ main_langs = { 'uk': 'Українська', 'zh': '简体中文' } +supported_languages = dict(lang_urls, **main_langs) # do search-request |