From a8912459a541f47fcf440c7054645e88098cd8e9 Mon Sep 17 00:00:00 2001 From: Mark Jaquith Date: Sun, 2 May 2010 06:02:54 +0000 Subject: [PATCH] Make sure alloptions is an array before we try to use unset() on its alleged key git-svn-id: https://develop.svn.wordpress.org/trunk@14330 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/functions.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-includes/functions.php b/wp-includes/functions.php index 899c39c7b2..c0e6c2c3c1 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -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' ); }