summaryrefslogtreecommitdiff
path: root/searx/engines/dailymotion.py
diff options
context:
space:
mode:
authorAlexandre Flament <alex@al-f.net>2015-05-02 15:45:17 +0200
committerAlexandre Flament <alex@al-f.net>2015-05-02 15:45:17 +0200
commit4689fe341ca7c7231d0409526b9ee0f2eadde445 (patch)
tree12d51f3471b2dfd448768cb8e540ee4668869453 /searx/engines/dailymotion.py
parentbbd83f5a519381ac7ea690a1645258d106a9ba8a (diff)
downloadsearxng-4689fe341ca7c7231d0409526b9ee0f2eadde445.tar.gz
searxng-4689fe341ca7c7231d0409526b9ee0f2eadde445.zip
update versions.cfg to use the current up-to-date packages
Diffstat (limited to 'searx/engines/dailymotion.py')
-rw-r--r--searx/engines/dailymotion.py26
1 files changed, 14 insertions, 12 deletions
diff --git a/searx/engines/dailymotion.py b/searx/engines/dailymotion.py
index 03b1dbb8b..4b029205a 100644
--- a/searx/engines/dailymotion.py
+++ b/searx/engines/dailymotion.py
@@ -1,14 +1,16 @@
-## Dailymotion (Videos)
-#
-# @website https://www.dailymotion.com
-# @provide-api yes (http://www.dailymotion.com/developer)
-#
-# @using-api yes
-# @results JSON
-# @stable yes
-# @parse url, title, thumbnail, publishedDate, embedded
-#
-# @todo set content-parameter with correct data
+"""
+ Dailymotion (Videos)
+
+ @website https://www.dailymotion.com
+ @provide-api yes (http://www.dailymotion.com/developer)
+
+ @using-api yes
+ @results JSON
+ @stable yes
+ @parse url, title, thumbnail, publishedDate, embedded
+
+ @todo set content-parameter with correct data
+"""
from urllib import urlencode
from json import loads
@@ -48,7 +50,7 @@ def response(resp):
search_res = loads(resp.text)
# return empty array if there are no results
- if not 'list' in search_res:
+ if 'list' not in search_res:
return []
# parse results