Refine early bailing checks in customize.php. see #20852.

git-svn-id: https://develop.svn.wordpress.org/trunk@20858 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2012-05-23 21:00:02 +00:00
parent 18c7acb94b
commit 694228f319

View File

@ -9,13 +9,10 @@
require_once( './admin.php' );
if ( ! current_user_can( 'edit_theme_options' ) )
die( 'Cap check failed' );
wp_die( __( 'Cheatin’ uh?' ) );
global $wp_scripts, $wp_customize;
if ( ! $wp_customize->is_preview() )
die( 'is_preview() failed' );
wp_reset_vars( array( 'theme' ) );
if ( ! $theme )