old archives might not have a comment in metadata, see #9208

guess the default is only needed when transferring
very old archives from borg1 repos.
This commit is contained in:
Thomas Waldmann 2025-12-04 02:05:22 +01:00
parent 425fa1c77a
commit 352f982393
No known key found for this signature in database
GPG key ID: 243ACFA951F78E01

View file

@ -151,7 +151,7 @@ class Archives:
hostname=archive_item.hostname,
size=archive_item.get("size", 0),
nfiles=archive_item.get("nfiles", 0),
comment=archive_item.comment, # not always present?
comment=archive_item.get("comment", ""),
tags=tuple(sorted(getattr(archive_item, "tags", []))), # must be hashable
)
return metadata