Don't cache option values while installing. See #12140.

git-svn-id: https://develop.svn.wordpress.org/trunk@14502 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Peter Westwood 2010-05-07 18:32:20 +00:00
parent 5c534591ae
commit f5d0ab2f21
1 changed files with 2 additions and 1 deletions

View File

@ -338,7 +338,8 @@ function get_option( $option, $default = false ) {
// Has to be get_row instead of get_var because of funkiness with 0, false, null values
if ( is_object( $row ) ) {
$value = $row->option_value;
wp_cache_add( $option, $value, 'options' );
if ( ! defined( 'WP_INSTALLING' ) )
wp_cache_add( $option, $value, 'options' );
} else { // option does not exist, so we must cache its non-existence
$notoptions[$option] = true;
wp_cache_set( 'notoptions', $notoptions, 'options' );