summaryrefslogtreecommitdiff
path: root/searx/engines/deviantart.py
diff options
context:
space:
mode:
authorAdam Tauber <asciimoo@gmail.com>2016-07-26 00:22:05 +0200
committerAdam Tauber <asciimoo@gmail.com>2016-07-26 00:28:48 +0200
commit350a84520d9da2499ffd5b0fbe6218692f2a330d (patch)
tree03dd22bea46a817084d782feef8df63f8cd2b375 /searx/engines/deviantart.py
parent3a8d193d1f746165df35e573f18c7abee970feb0 (diff)
downloadsearxng-350a84520d9da2499ffd5b0fbe6218692f2a330d.tar.gz
searxng-350a84520d9da2499ffd5b0fbe6218692f2a330d.zip
[fix] time range detection
Diffstat (limited to 'searx/engines/deviantart.py')
-rw-r--r--searx/engines/deviantart.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/searx/engines/deviantart.py b/searx/engines/deviantart.py
index ef1dd9e5f..d893fc7fe 100644
--- a/searx/engines/deviantart.py
+++ b/searx/engines/deviantart.py
@@ -13,7 +13,6 @@
"""
from urllib import urlencode
-from urlparse import urljoin
from lxml import html
import re
from searx.engines.xpath import extract_text
@@ -39,7 +38,7 @@ def request(query, params):
params['url'] = search_url.format(offset=offset,
query=urlencode({'q': query}))
- if params['time_range']:
+ if params['time_range'] in time_range_dict:
params['url'] += time_range_url.format(range=time_range_dict[params['time_range']])
return params