Commit 18379dea authored by Chris's avatar Chris
Browse files

check for text attr and save

parent edcff9ab
......@@ -235,6 +235,7 @@ class PromptServer():
if os.path.isfile(file):
with Image.open(file) as original_pil:
metadata = PngInfo()
if hasattr(original_pil,'text'):
for key in original_pil.text:
metadata.add_text(key, original_pil.text[key])
original_pil = original_pil.convert('RGBA')
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment