mirror of
https://github.com/searxng/searxng.git
synced 2025-12-26 13:40:03 +00:00
[mod] searx.RawTextQuery: the constructor call parse_query
This commit is contained in:
@@ -45,10 +45,11 @@ class RawTextQuery:
|
||||
self.timeout_limit = None
|
||||
self.external_bang = None
|
||||
self.specific = False
|
||||
self._parse_query()
|
||||
|
||||
# parse query, if tags are set, which
|
||||
# change the search engine or search-language
|
||||
def parse_query(self):
|
||||
def _parse_query(self):
|
||||
self.query_parts = []
|
||||
|
||||
# split query, including whitespaces
|
||||
|
||||
@@ -266,7 +266,6 @@ def get_search_query_from_webapp(preferences, form):
|
||||
# parse query, if tags are set, which change
|
||||
# the serch engine or search-language
|
||||
raw_text_query = RawTextQuery(form['q'], disabled_engines)
|
||||
raw_text_query.parse_query()
|
||||
|
||||
# set query
|
||||
query = raw_text_query.getSearchQuery()
|
||||
|
||||
@@ -737,7 +737,6 @@ def autocompleter():
|
||||
|
||||
# parse query
|
||||
raw_text_query = RawTextQuery(str(request.form.get('q', b'')), disabled_engines)
|
||||
raw_text_query.parse_query()
|
||||
|
||||
# check if search query is set
|
||||
if not raw_text_query.getSearchQuery():
|
||||
|
||||
Reference in New Issue
Block a user