From dd8385ccd8f17a679ea34d26618fbdc87858486c Mon Sep 17 00:00:00 2001 From: Mike Lang Date: Fri, 4 Nov 2022 16:59:39 +1100 Subject: [PATCH] sheetsync: Special case "" in playlist tags to mean [] this avoids empty string meaning [] which is dangerous since it's easy to write accidentially. --- sheetsync/sheetsync/main.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sheetsync/sheetsync/main.py b/sheetsync/sheetsync/main.py index b212d00..30876e9 100644 --- a/sheetsync/sheetsync/main.py +++ b/sheetsync/sheetsync/main.py @@ -370,6 +370,10 @@ class SheetSync(object): tags = self.column_parsers['tags'](tags) if not tags: continue + # special-case for the "all everything" list, + # we don't want "no tags" to mean "all videos" so we need a sentinel value. + if tags == [""]: + tags = [] playlist_id = playlist_id.strip() if len(playlist_id) != 34 or not playlist_id.startswith('PL'): continue