Skip to content

Commit

Permalink
recommendations: short circuit when there is no history
Browse files Browse the repository at this point in the history
  • Loading branch information
anxdpanic committed May 8, 2020
1 parent 23a7993 commit d804c35
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions resources/lib/youtube_plugin/youtube/client/youtube.py
Expand Up @@ -328,6 +328,9 @@ def helper(video_id, responses):

history = self.get_watch_history()
result = {'kind': 'youtube#activityListResponse', 'items': []}
if not history.get('items'):
return result

threads = []
candidates = []
already_fetched_for_video_ids = [item['plugin_fetched_for'] for item in items]
Expand Down

0 comments on commit d804c35

Please sign in to comment.