diff options
| author | Markus Heiser <markus.heiser@darmarit.de> | 2021-05-24 16:31:14 +0200 |
|---|---|---|
| committer | Markus Heiser <markus.heiser@darmarit.de> | 2021-05-24 16:31:14 +0200 |
| commit | f963759ccc8b7598db780fc112551c03aadde51e (patch) | |
| tree | 50e65879dc77358149411f83ba1c7438ce57a8d3 | |
| parent | 3a71d4b1757a6802fc36c637918bf0dc65737415 (diff) | |
[fix] engine genius should not use the video template
Remove 'template' from result. Engine genius should
not use the video template. BTW: fix indentations
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
| -rw-r--r-- | searx/engines/genius.py | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/searx/engines/genius.py b/searx/engines/genius.py index 86bab1f8f..9d701a8de 100644 --- a/searx/engines/genius.py +++ b/searx/engines/genius.py @@ -48,11 +48,12 @@ def parse_lyric(hit): logger.error(e, exc_info=True) content = '' timestamp = hit['result']['lyrics_updated_at'] - result = {'url': hit['result']['url'], - 'title': hit['result']['full_title'], - 'content': content, - 'thumbnail': hit['result']['song_art_image_thumbnail_url'], - 'template': 'videos.html'} + result = { + 'url': hit['result']['url'], + 'title': hit['result']['full_title'], + 'content': content, + 'thumbnail': hit['result']['song_art_image_thumbnail_url'], + } if timestamp: result.update({'publishedDate': datetime.fromtimestamp(timestamp)}) return result @@ -69,12 +70,12 @@ def parse_artist(hit): def parse_album(hit): - result = {'url': hit['result']['url'], - 'title': hit['result']['full_title'], - 'thumbnail': hit['result']['cover_art_url'], - 'content': '', - # 'thumbnail': hit['result']['cover_art_thumbnail_url'], - 'template': 'videos.html'} + result = { + 'url': hit['result']['url'], + 'title': hit['result']['full_title'], + 'thumbnail': hit['result']['cover_art_url'], + 'content': '', + } try: year = hit['result']['release_date_components']['year'] except Exception as e: # pylint: disable=broad-except |