Formating

This commit is contained in:
Ahmed 2024-09-02 16:40:58 +00:00 committed by GitHub
parent 9f9a937b37
commit f8426feb61
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -260,6 +260,7 @@ def load_svg_image(file: bytes, resize: tuple[int, int]):
return Image.open(io.BytesIO(svg_image))
def invert_image_colors(image):
from PIL import Image
@ -271,6 +272,7 @@ def invert_image_colors(image):
r, g, b = map(invert, (r, g, b))
return Image.merge(image.mode, (r, g, b, a))
async def to_code(config):
# Local import only to allow "validate_pillow_installed" to run *before* importing it
from PIL import Image