Ability for extensions to return custom data via api in response.images

This commit is contained in:
FluttyProger 2023-10-01 18:06:48 +03:00 committed by GitHub
parent e3c849da06
commit f71e919ecb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -103,7 +103,8 @@ def decode_base64_to_image(encoding):
def encode_pil_to_base64(image):
with io.BytesIO() as output_bytes:
if isinstance(image, str):
return image
if opts.samples_format.lower() == 'png':
use_metadata = False
metadata = PngImagePlugin.PngInfo()