Ticket #18422: 18422.diff
| File 18422.diff, 988 bytes (added by , 15 years ago) |
|---|
-
wp-includes/functions.php
586 586 * @param mixed $value Optional. Option value, can be anything. Expected to not be SQL-escaped. 587 587 * @param mixed $deprecated Optional. Description. Not used anymore. 588 588 * @param bool $autoload Optional. Default is enabled. Whether to load the option when WordPress starts up. 589 * @return null returns when finished.589 * @return bool False if option was not added and true if option was added. 590 590 */ 591 591 function add_option( $option, $value = '', $deprecated = '', $autoload = 'yes' ) { 592 592 global $wpdb; … … 609 609 $notoptions = wp_cache_get( 'notoptions', 'options' ); 610 610 if ( !is_array( $notoptions ) || !isset( $notoptions[$option] ) ) 611 611 if ( false !== get_option( $option ) ) 612 return ;612 return false; 613 613 614 614 $_value = $value; 615 615 $value = maybe_serialize( $value );