mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-26 18:06:18 +03:00
Fix deprecation warning
Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
This commit is contained in:
parent
c9acb9b387
commit
136d1a89df
|
@ -68,7 +68,7 @@ def __getattr__(name):
|
||||||
"ANTIALIAS": "LANCZOS",
|
"ANTIALIAS": "LANCZOS",
|
||||||
}
|
}
|
||||||
if name in old_resampling:
|
if name in old_resampling:
|
||||||
deprecate(name, 10, old_resampling[name])
|
deprecate(name, 10, f"Resampling.{old_resampling[name]}")
|
||||||
return Resampling[old_resampling[name]]
|
return Resampling[old_resampling[name]]
|
||||||
for enum in (Transpose, Transform, Resampling, Dither, Palette, Quantize):
|
for enum in (Transpose, Transform, Resampling, Dither, Palette, Quantize):
|
||||||
if name in enum.__members__:
|
if name in enum.__members__:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user