mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-11 12:20:22 +00:00
array_shift() error fixes from DD32. fixes #6499 for trunk
git-svn-id: https://develop.svn.wordpress.org/trunk@7713 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -18,7 +18,7 @@ if ( isset($_GET['sidebar']) && isset($wp_registered_sidebars[$_GET['sidebar']])
|
||||
$sidebar = attribute_escape( $_GET['sidebar'] );
|
||||
} elseif ( is_array($wp_registered_sidebars) && !empty($wp_registered_sidebars) ) {
|
||||
// By default we look at the first defined sidebar
|
||||
$sidebar = array_shift( array_keys($wp_registered_sidebars) );
|
||||
$sidebar = array_shift( $keys = array_keys($wp_registered_sidebars) );
|
||||
} else {
|
||||
// If no sidebars, die.
|
||||
require_once( 'admin-header.php' );
|
||||
|
||||
Reference in New Issue
Block a user