From 0e1783172411250d7abad9ed8935d805c74941d6 Mon Sep 17 00:00:00 2001 From: Colin Powell Date: Thu, 12 Jan 2023 23:38:34 -0500 Subject: [PATCH] Fix bug in load extra video info --- vrobbler/apps/scrobbles/views.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/vrobbler/apps/scrobbles/views.py b/vrobbler/apps/scrobbles/views.py index 1383154..aa2a774 100644 --- a/vrobbler/apps/scrobbles/views.py +++ b/vrobbler/apps/scrobbles/views.py @@ -61,10 +61,14 @@ class RecentScrobbleList(ListView): data['now_playing_list'] = Scrobble.objects.filter( in_progress=True, is_paused=False, + modified__gte=last_eight_minutes, timestamp__lte=now, ) data['video_scrobble_list'] = Scrobble.objects.filter( - video__isnull=False, in_progress=False + video__isnull=False, played_to_completion=True + ).order_by('-timestamp')[:10] + data['podcast_scrobble_list'] = Scrobble.objects.filter( + podcast_episode__isnull=False, played_to_completion=True ).order_by('-timestamp')[:10] data['top_daily_tracks'] = top_tracks() data['top_weekly_tracks'] = top_tracks(filter='week')