#58271 closed defect (bug) (fixed)
Docs: WP_Image_Editor classes have incorrect type for $crop in docblocks
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Milestone: | 6.3 | Priority: | normal |
| Severity: | trivial | Version: | |
| Component: | Media | Keywords: | has-patch |
| Focuses: | docs | Cc: |
Description
The docblocks for the WP_Image_Editor resize() and multi_resize() functions indicate that $crop is of type bool, instead of bool|array. The implementations of these functions by WP_Image_Editor_Imagick and WP_Image_Editor_GD also have these docblock errors, and they additionally both have the error in the docblock for their make_subsize() functions.
The $crop docblock type should match the type documented in image_resize_dimensions().
Affected files:
wp-includes/class-wp-image-editor-gd.phpwp-includes/class-wp-image-editor-imagick.phpwp-includes/class-wp-image-editor.php
Change History (7)
This ticket was mentioned in βPR #4434 on βWordPress/wordpress-develop by βthunderdw.
3 years ago
#2
- Keywords has-patch added
This ticket was mentioned in βSlack in #core-media by antpb. βView the logs.
3 years ago
This ticket was mentioned in βSlack in #core by mukeshpanchal27. βView the logs.
2 years ago
#5
@
2 years ago
- Owner changed from thunderdw to audrasjb
- Status changed from assigned to reviewing
Self assigning for review/commit.
β@audrasjb commented on βPR #4434:
2 years ago
#7
committed in https://core.trac.wordpress.org/changeset/56204
Trac ticket: https://core.trac.wordpress.org/ticket/58271