Make WordPress Core


Ignore:
Timestamp:
07/17/2014 05:37:51 PM (10 years ago)
Author:
wonderboymusic
Message:

After [29197], use ! empty() instead of isset(). Don't call has_shortcode() internally twice if it's true.

Props kovshenin.
Fixes #26343.

File:
1 edited

Legend:

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

    r29197 r29207  
    168168            if ( $tag === $shortcode[2] ) {
    169169                return true;
    170             } elseif ( isset( $shortcode[5] ) && has_shortcode( $shortcode[5], $tag ) ) {
    171                 return has_shortcode( $shortcode[5], $tag );
     170            } elseif ( ! empty( $shortcode[5] ) && has_shortcode( $shortcode[5], $tag ) ) {
     171                return true;
    172172            }
    173173        }
Note: See TracChangeset for help on using the changeset viewer.