WordPress.org

Make WordPress Core

Ticket #52183: 52183.3.diff

File 52183.3.diff, 2.0 KB (added by audrasjb, 8 months ago)

DocBlocks Coding standards fixes

  • src/wp-includes/media.php

    diff --git a/src/wp-includes/media.php b/src/wp-includes/media.php
    index 11b6fae7d1..9df28c2a12 100644
    a b function wp_get_attachment_image( $attachment_id, $size = 'thumbnail', $icon = f 
    11241124 * @param string|int[] $size          Optional. Image size. Accepts any registered image size name, or an array of
    11251125 *                                    width and height values in pixels (in that order). Default 'thumbnail'.
    11261126 * @param bool         $icon          Optional. Whether the image should be treated as an icon. Default false.
    1127  * @return string|false Attachment URL or false if no image is available.
     1127 * @return string|false Attachment URL or false if no image is available. If `$size` doesn't match any registered
     1128 *                      image size, the original image URL will be returned.
    11281129 */
    11291130function wp_get_attachment_image_url( $attachment_id, $size = 'thumbnail', $icon = false ) {
    11301131        $image = wp_get_attachment_image_src( $attachment_id, $size, $icon );
  • src/wp-includes/post-thumbnail-template.php

    diff --git a/src/wp-includes/post-thumbnail-template.php b/src/wp-includes/post-thumbnail-template.php
    index 1605afa27b..bf2375929d 100644
    a b function get_the_post_thumbnail( $post = null, $size = 'post-thumbnail', $attr = 
    217217 * @param int|WP_Post  $post Optional. Post ID or WP_Post object.  Default is global `$post`.
    218218 * @param string|int[] $size Optional. Registered image size to retrieve the source for or a flat
    219219 *                           array of height and width dimensions. Default 'post-thumbnail'.
    220  * @return string|false Post thumbnail URL or false if no URL is available.
     220 * @return string|false Post thumbnail URL or false if no image is available. If `$size` doesn't
     221 *                      match any registered image size, the original image URL will be returned.
    221222 */
    222223function get_the_post_thumbnail_url( $post = null, $size = 'post-thumbnail' ) {
    223224        $post_thumbnail_id = get_post_thumbnail_id( $post );