aboutsummaryrefslogtreecommitdiffstats
path: root/youtube/subscriptions.py
diff options
context:
space:
mode:
authorJames Taylor <user234683@users.noreply.github.com>2019-08-17 12:54:03 -0700
committerJames Taylor <user234683@users.noreply.github.com>2019-08-17 12:54:03 -0700
commitaa5b9efca11f4fe52f176f378bd6ed96290ad9d0 (patch)
tree483b98549c61b231ed35a1341d2f836676fd251e /youtube/subscriptions.py
parent897755e836f5ac043a683ac44e9f047184b63f6e (diff)
downloadyt-local-aa5b9efca11f4fe52f176f378bd6ed96290ad9d0.tar.lz
yt-local-aa5b9efca11f4fe52f176f378bd6ed96290ad9d0.tar.xz
yt-local-aa5b9efca11f4fe52f176f378bd6ed96290ad9d0.zip
Subscriptions: Don't show videos from muted channels
Diffstat (limited to 'youtube/subscriptions.py')
-rw-r--r--youtube/subscriptions.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/youtube/subscriptions.py b/youtube/subscriptions.py
index 26958d0..a4fef5a 100644
--- a/youtube/subscriptions.py
+++ b/youtube/subscriptions.py
@@ -144,13 +144,14 @@ def _get_videos(cursor, number_per_page, offset, tag = None):
FROM videos
INNER JOIN subscribed_channels on videos.sql_channel_id = subscribed_channels.id
INNER JOIN tag_associations on videos.sql_channel_id = tag_associations.sql_channel_id
- WHERE tag = ?
+ WHERE tag = ? AND muted = 0
ORDER BY time_published DESC
LIMIT ? OFFSET ?''', (tag, number_per_page*9, offset)).fetchall()
else:
db_videos = cursor.execute('''SELECT video_id, title, duration, time_published, is_time_published_exact, channel_name
FROM videos
INNER JOIN subscribed_channels on videos.sql_channel_id = subscribed_channels.id
+ WHERE muted = 0
ORDER BY time_published DESC
LIMIT ? OFFSET ?''', (number_per_page*9, offset)).fetchall()