Return to step 1 on custom-header.php if not POST data is sent. Good for if step=2 or 3 is in the URL and the page is refreshed (otherwise a nonce check fails). see #20249.

git-svn-id: https://develop.svn.wordpress.org/trunk@20211 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2012-03-19 14:45:29 +00:00
parent 4a99a54b23
commit 866e4df183
1 changed files with 1 additions and 1 deletions

View File

@ -894,7 +894,7 @@ wp_nonce_field( 'custom-header-options', '_wpnonce-custom-header-options' ); ?>
if ( ! current_user_can('edit_theme_options') )
wp_die(__('You do not have permission to customize headers.'));
$step = $this->step();
if ( 1 == $step )
if ( 1 == $step || ! $_POST )
$this->step_1();
elseif ( 2 == $step )
$this->step_2();