WordPress.org

Make WordPress Core

Ticket #34549: 34549.2.diff

File 34549.2.diff, 965 bytes (added by danielbachhuber, 5 years ago)
  • src/wp-includes/customize/class-wp-customize-themes-section.php

    diff --git src/wp-includes/customize/class-wp-customize-themes-section.php src/wp-includes/customize/class-wp-customize-themes-section.php
    index ecd7833..2470240 100644
    class WP_Customize_Themes_Section extends WP_Customize_Section { 
    4545                                        echo '<span class="customize-action">' . __( 'Previewing theme' ) . '</span> ' . $this->title;
    4646                                }
    4747                                ?>
    48 
    49                                 <button type="button" class="button change-theme" tabindex="0"><?php _ex( 'Change', 'theme' ); ?></button>
     48                                <?php if ( count( wp_prepare_themes_for_js() ) > 1 ) : ?>
     49                                        <button type="button" class="button change-theme" tabindex="0"><?php _ex( 'Change', 'theme' ); ?></button>
     50                                <?php endif; ?>
    5051                        </h3>
    5152                        <div class="customize-themes-panel control-panel-content themes-php">
    5253                                <h3 class="accordion-section-title customize-section-title">