Fix direct access to private member
This commit is contained in:
@@ -19,10 +19,8 @@ class CropImage(ImageManipulation):
|
|||||||
image: The image to manipulate
|
image: The image to manipulate
|
||||||
parameters: Parameters for the manipulation (e.g., crop coordinates)
|
parameters: Parameters for the manipulation (e.g., crop coordinates)
|
||||||
"""
|
"""
|
||||||
if image is None or getattr(image, "_imageData", None) is None:
|
|
||||||
return
|
|
||||||
|
|
||||||
pil_image = image._imageData
|
pil_image = image.getImage()
|
||||||
|
|
||||||
# If parameters provided as dict with width/height, do centered crop
|
# If parameters provided as dict with width/height, do centered crop
|
||||||
if isinstance(parameters, dict) and "width" in parameters and "height" in parameters:
|
if isinstance(parameters, dict) and "width" in parameters and "height" in parameters:
|
||||||
|
|||||||
Reference in New Issue
Block a user