commit: 66f02dc2b6b0c6127ba908ad9be3a97dfd633f7f
parent: 84c3251bdc86052acb8a1baf92684417eb362edc
Author: Adam Tauber <asciimoo@gmail.com>
Date: Wed, 9 Jul 2014 01:18:37 +0200
[fix] unused globals removed
Diffstat:
7 files changed, 0 insertions(+), 8 deletions(-)
diff --git a/searx/engines/bing.py b/searx/engines/bing.py
@@ -27,7 +27,6 @@ def request(query, params):
def response(resp):
- global base_url
results = []
dom = html.fromstring(resp.content)
for result in dom.xpath('//div[@class="sa_cc"]'):
diff --git a/searx/engines/bing_news.py b/searx/engines/bing_news.py
@@ -29,7 +29,6 @@ def request(query, params):
def response(resp):
- global base_url
results = []
dom = html.fromstring(resp.content)
for result in dom.xpath('//div[@class="sa_cc"]'):
diff --git a/searx/engines/currency_convert.py b/searx/engines/currency_convert.py
@@ -31,7 +31,6 @@ def request(query, params):
def response(resp):
- global base_url
results = []
try:
_, conversion_rate, _ = resp.text.split(',', 2)
diff --git a/searx/engines/deviantart.py b/searx/engines/deviantart.py
@@ -18,7 +18,6 @@ def request(query, params):
def response(resp):
- global base_url
results = []
if resp.status_code == 302:
return results
diff --git a/searx/engines/github.py b/searx/engines/github.py
@@ -10,7 +10,6 @@ accept_header = 'application/vnd.github.preview.text-match+json'
def request(query, params):
- global search_url
params['url'] = search_url.format(query=urlencode({'q': query}))
params['headers']['Accept'] = accept_header
return params
diff --git a/searx/engines/soundcloud.py b/searx/engines/soundcloud.py
@@ -18,7 +18,6 @@ def request(query, params):
def response(resp):
- global base_url
results = []
search_res = loads(resp.text)
for result in search_res.get('collection', []):
diff --git a/searx/engines/twitter.py b/searx/engines/twitter.py
@@ -12,13 +12,11 @@ content_xpath = './/p[@class="js-tweet-text tweet-text"]//text()'
def request(query, params):
- global search_url
params['url'] = search_url + urlencode({'q': query})
return params
def response(resp):
- global base_url
results = []
dom = html.fromstring(resp.text)
for tweet in dom.xpath('//li[@data-item-type="tweet"]'):