From 7dfb7b25447d8ca1b05550a27b7bc483ab2e530b Mon Sep 17 00:00:00 2001 From: Mike Lang Date: Mon, 7 Nov 2022 12:25:28 +1100 Subject: [PATCH] sheetsync: Fix a bug where only show-in-description playlists were detected Because a blank 5th column would make sheetsync ignore the row. --- sheetsync/sheetsync/main.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sheetsync/sheetsync/main.py b/sheetsync/sheetsync/main.py index 30876e9..a06982f 100644 --- a/sheetsync/sheetsync/main.py +++ b/sheetsync/sheetsync/main.py @@ -364,9 +364,13 @@ class SheetSync(object): overwriting the entire playlists table""" playlists = [] for row in rows: - if len(row) != 5: + if len(row) == 5: + tags, _, name, playlist_id, show_in_description = row + elif len(row) == 4: + tags, _, name, playlist_id = row + show_in_description = "" + else: continue - tags, _, name, playlist_id, show_in_description = row tags = self.column_parsers['tags'](tags) if not tags: continue