images: force-cast to bool inside Icon

reported in #86
This commit is contained in:
Luna 2020-02-08 13:28:29 -03:00
parent c3b281c940
commit 39e8a1ad7e
1 changed files with 1 additions and 1 deletions

View File

@ -99,7 +99,7 @@ class Icon:
return get_ext(self.mime) return get_ext(self.mime)
def __bool__(self): def __bool__(self):
return self.key and self.icon_hash and self.mime return bool(self.key and self.icon_hash and self.mime)
class ImageError(Exception): class ImageError(Exception):