From f9e45047c16caaf82728ed267929f703895bfc02 Mon Sep 17 00:00:00 2001 From: Drew Jaynes Date: Mon, 21 Sep 2015 10:21:48 +0000 Subject: [PATCH] Docs: Add a more complete return description for the array of data (or false) returned by `image_downsize()`. If not short-circuited via the `image_downsize` boolean filter, `image_downsize()` returns an array of data including the image URL, width, height, and whether the image size is intermediate, in that order. Otherwise, it returns false. Fixes #30636. git-svn-id: https://develop.svn.wordpress.org/trunk@34362 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/media.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/wp-includes/media.php b/src/wp-includes/media.php index a7db3213fd..527e5dbc22 100644 --- a/src/wp-includes/media.php +++ b/src/wp-includes/media.php @@ -148,7 +148,8 @@ function image_hwstring( $width, $height ) { * @param int $id Attachment ID for image. * @param array|string $size Optional. Image size to scale to. Accepts a registered image size * or flat array of height and width values. Default 'medium'. - * @return false|array False on failure, array on success. + * @return false|array Array containing the image URL, width, height, and boolean for whether + * the image is an intermediate size. False on failure. */ function image_downsize( $id, $size = 'medium' ) {