WordPress.org

Make WordPress Core


Ignore:
Timestamp:
09/19/2017 08:38:43 AM (2 years ago)
Author:
ocean90
Message:

Customize: Ensure valid themes in the preview.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-customize-manager.php

    r41390 r41397  
    272272
    273273        $this->original_stylesheet = get_stylesheet();
    274         $this->theme = wp_get_theme( $args['theme'] );
     274        $this->theme = wp_get_theme( 0 === validate_file( $args['theme'] ) ? $args['theme'] : null );
    275275        $this->messenger_channel = $args['messenger_channel'];
    276276        $this->settings_previewed = ! empty( $args['settings_previewed'] );
Note: See TracChangeset for help on using the changeset viewer.