mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-02-03 21:24:31 +03:00
Accept lists as well
This commit is contained in:
parent
d4b2fa7348
commit
62ece989dc
|
@ -1400,9 +1400,9 @@ class Image(object):
|
|||
Performance Note: Not currently implemented in-place in the core layer.
|
||||
"""
|
||||
|
||||
if not isinstance(source, tuple):
|
||||
if not isinstance(source, (list, tuple)):
|
||||
raise ValueError("Source must be a tuple")
|
||||
if not isinstance(dest, tuple):
|
||||
if not isinstance(dest, (list, tuple)):
|
||||
raise ValueError("Destination must be a tuple")
|
||||
if not len(source) in (2, 4):
|
||||
raise ValueError("Source must be a 2 or 4-tuple")
|
||||
|
|
Loading…
Reference in New Issue
Block a user