From 223b3487c38a2390ad936943266a44da9cbb810a Mon Sep 17 00:00:00 2001 From: jazzzooo <38244149+jazzzooo@users.noreply.github.com> Date: Fri, 15 Sep 2023 00:53:03 -0700 Subject: [fix] spelling --- searx/engines/google.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'searx/engines/google.py') diff --git a/searx/engines/google.py b/searx/engines/google.py index 377c8db39..51c6acbf2 100644 --- a/searx/engines/google.py +++ b/searx/engines/google.py @@ -22,7 +22,7 @@ import babel.core import babel.languages from searx.utils import extract_text, eval_xpath, eval_xpath_list, eval_xpath_getindex -from searx.locales import language_tag, region_tag, get_offical_locales +from searx.locales import language_tag, region_tag, get_official_locales from searx.network import get # see https://github.com/searxng/searxng/issues/762 from searx.exceptions import SearxEngineCaptchaException from searx.enginelib.traits import EngineTraits @@ -184,8 +184,8 @@ def get_google_info(params, eng_traits): # # To select 'all' languages an empty 'lr' value is used. # - # Different to other google services, Google Schloar supports to select more - # than one language. The languages are seperated by a pipe '|' (logical OR). + # Different to other google services, Google Scholar supports to select more + # than one language. The languages are separated by a pipe '|' (logical OR). # By example: &lr=lang_zh-TW%7Clang_de selects articles written in # traditional chinese OR german language. @@ -204,7 +204,7 @@ def get_google_info(params, eng_traits): if len(sxng_locale.split('-')) > 1: ret_val['params']['cr'] = 'country' + country - # gl parameter: (mandatory by Geeogle News) + # gl parameter: (mandatory by Google News) # The gl parameter value is a two-letter country code. For WebSearch # results, the gl parameter boosts search results whose country of origin # matches the parameter value. See the Country Codes section for a list of @@ -465,7 +465,7 @@ def fetch_traits(engine_traits: EngineTraits, add_domains: bool = True): engine_traits.all_locale = 'ZZ' continue - sxng_locales = get_offical_locales(eng_country, engine_traits.languages.keys(), regional=True) + sxng_locales = get_official_locales(eng_country, engine_traits.languages.keys(), regional=True) if not sxng_locales: print("ERROR: can't map from google country %s (%s) to a babel region." % (x.get('data-name'), eng_country)) -- cgit v1.2.3