Make WordPress Core

Ticket #20852: 20852.diff

File 20852.diff, 558 bytes (added by lancewillett, 12 years ago)
  • wp-admin/customize.php

     
    1818if ( ! $theme )
    1919        $theme = get_stylesheet();
    2020
     21// Make sure theme exists first, and is allowed (multisite only).
     22$theme = wp_get_theme( $theme );
     23if ( ! $theme->exists() || ! $theme->is_allowed() )
     24        wp_die( __( 'Cheatin’ uh?' ) );
     25
    2126$registered = $wp_scripts->registered;
    2227$wp_scripts = new WP_Scripts;
    2328$wp_scripts->registered = $registered;