Remove try/except in img metadata read

This commit is contained in:
catboxanon 2023-05-25 08:33:40 -04:00 committed by GitHub
parent 7a1bbf99da
commit 60062b51d8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -668,10 +668,7 @@ def read_info_from_image(image):
for field in ['jfif', 'jfif_version', 'jfif_unit', 'jfif_density', 'dpi', 'exif',
'loop', 'background', 'timestamp', 'duration', 'progressive', 'progression',
'icc_profile', 'chromaticity']:
try:
items.pop(field, None)
except KeyError:
pass
items.pop(field, None)
if items.get("Software", None) == "NovelAI":
try: