diff options
Diffstat (limited to '3_archive.py')
-rw-r--r-- | 3_archive.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/3_archive.py b/3_archive.py index 39affdd..258392b 100644 --- a/3_archive.py +++ b/3_archive.py @@ -74,7 +74,10 @@ def collect_note(id: str): output["attachments"] = [] for file_id in file_ids: time.sleep(0.0005) - name, type_, comment, url = conn.execute('select name, type, comment, url from drive_file where id = %s', [file_id]).fetchone() + row = conn.execute('select name, type, comment, url from drive_file where id = %s', [file_id]).fetchone() + if row is None: + continue + name, type_, comment, url = row attachment = { "id": file_id, "type": type_, |