Make WordPress Core

Changeset 58168


Ignore:
Timestamp:
05/18/2024 03:19:09 PM (4 weeks ago)
Author:
SergeyBiryukov
Message:

Shortcodes: Remove redundant variable type check in get_post_galleries().

shortcode_parse_atts() always returns an array as of [57597], so the check is no longer needed.

Follow-up to [40070], [57597].

Props david.binda, swissspidy, oglekler.
Fixes #60581.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/media.php

    r58146 r58168  
    50805080
    50815081                $shortcode_attrs = shortcode_parse_atts( $shortcode[3] );
    5082                 if ( ! is_array( $shortcode_attrs ) ) {
    5083                     $shortcode_attrs = array();
    5084                 }
    50855082
    50865083                // Specify the post ID of the gallery we're viewing if the shortcode doesn't reference another post already.
Note: See TracChangeset for help on using the changeset viewer.