From 231ac1e012af3961f8c498af023d3cd5ba4b9606 Mon Sep 17 00:00:00 2001 From: simon Date: Mon, 30 May 2022 17:59:52 +0700 Subject: [PATCH] make channel matching optional for reusability --- tubearchivist/home/src/download/queue.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tubearchivist/home/src/download/queue.py b/tubearchivist/home/src/download/queue.py index 47225dd4..c115fbc1 100644 --- a/tubearchivist/home/src/download/queue.py +++ b/tubearchivist/home/src/download/queue.py @@ -269,9 +269,12 @@ class PendingList(PendingIndex): "vid_thumb_url": vid["thumbnail"], "title": vid["title"], "channel_id": vid["channel_id"], - "channel_indexed": vid["channel_id"] in self.all_channels, "duration": duration_str, "published": published, "timestamp": int(datetime.now().strftime("%s")), } + if self.all_channels: + youtube_details.update( + {"channel_indexed": vid["channel_id"] in self.all_channels} + ) return youtube_details