Merge pull request #74 from carsonreinke/fix-typeerror

Missing format specifier for arguments of image status
This commit is contained in:
Kilian Valkhof 2020-09-30 13:21:24 +02:00 committed by GitHub
commit c21089f97b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -304,6 +304,7 @@ class ImageRow:
def __init__(self, image, waitingIcon=None): def __init__(self, image, waitingIcon=None):
"""Build the information visible in the table image row.""" """Build the information visible in the table image row."""
self.image = image self.image = image
d = { d = {
'filename_w_ext': lambda i: self.statusStr() % i.filename_w_ext, 'filename_w_ext': lambda i: self.statusStr() % i.filename_w_ext,
'oldfilesizestr': lambda i: human_readable_size(i.oldfilesize) 'oldfilesizestr': lambda i: human_readable_size(i.oldfilesize)
@ -331,9 +332,9 @@ class ImageRow:
message = "Compressing %s..." message = "Compressing %s..."
return message return message
if not self.image.compressed and self.image.recompression: if not self.image.compressed and self.image.recompression:
return "Queued for recompression..." return "Queued for recompression %s..."
if not self.image.compressed: if not self.image.compressed:
return "Queued..." return "Queued %s..."
return "%s" return "%s"
def __getitem__(self, key): def __getitem__(self, key):