Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
radarhere committed Nov 29, 2024
1 parent 084a6ac commit e439b21
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/PIL/AvifImagePlugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,9 @@ def _open(self) -> None:
)
raise SyntaxError(msg)

if codec != "auto" and not _avif.decoder_codec_available(codec):
if DECODE_CODEC_CHOICE != "auto" and not _avif.decoder_codec_available(
DECODE_CODEC_CHOICE
):
msg = "Invalid opening codec"
raise ValueError(msg)
self._decoder = _avif.AvifDecoder(
Expand Down

0 comments on commit e439b21

Please sign in to comment.