Merge pull request #5915 from radarhere/load

This commit is contained in:
Hugo van Kemenade 2021-12-30 10:39:08 +02:00 committed by GitHub
commit 1d3fbf2049
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -812,7 +812,7 @@ class Image:
palette_length = self.im.putpalette(mode, arr)
self.palette.dirty = 0
self.palette.rawmode = None
if "transparency" in self.info and mode in ("RGBA", "LA", "PA"):
if "transparency" in self.info and mode in ("LA", "PA"):
if isinstance(self.info["transparency"], int):
self.im.putpalettealpha(self.info["transparency"], 0)
else: