Make sure alloptions is an array before we try to use unset() on its alleged key
git-svn-id: http://svn.automattic.com/wordpress/trunk@14330 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
f92971a7ff
commit
247c08f604
|
@ -637,7 +637,7 @@ function delete_option( $option ) {
|
|||
if ( ! defined( 'WP_INSTALLING' ) ) {
|
||||
if ( 'yes' == $row->autoload ) {
|
||||
$alloptions = wp_load_alloptions();
|
||||
if ( isset( $alloptions[$option] ) ) {
|
||||
if ( is_array( $alloptions ) && isset( $alloptions[$option] ) ) {
|
||||
unset( $alloptions[$option] );
|
||||
wp_cache_set( 'alloptions', $alloptions, 'options' );
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue