From cdb0fba2ede3e6a62ab9d3d2ce87cc35f40ce9eb Mon Sep 17 00:00:00 2001 From: Andrew Murray Date: Thu, 30 Dec 2021 11:45:40 +1100 Subject: [PATCH] Removed redundant part of condition --- src/PIL/Image.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PIL/Image.py b/src/PIL/Image.py index d5113a71f9e..e5ea25fc44f 100644 --- a/src/PIL/Image.py +++ b/src/PIL/Image.py @@ -812,7 +812,7 @@ def load(self): 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: