From 91878831dd159f55453defb41cda97833f43c2dc Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 25 Feb 2020 20:06:32 +0000 Subject: [PATCH] Docs: In `update_option()`, remove an inaccurate statement about the `$autoload` value for new options. If the option does not exist, it will be created with whatever was passed to the `$autoload` parameter, `'yes'` being only the default value. Props leogermani. Fixes #48357. git-svn-id: https://develop.svn.wordpress.org/trunk@47373 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/option.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/wp-includes/option.php b/src/wp-includes/option.php index 48bbe3beb5..51dc8cc153 100644 --- a/src/wp-includes/option.php +++ b/src/wp-includes/option.php @@ -283,8 +283,7 @@ function wp_load_core_site_options( $network_id = null ) { * then it will be serialized before it is inserted into the database. * Remember, resources cannot be serialized or added as an option. * - * If the option does not exist, then the option will be added with the option value, - * with an `$autoload` value of 'yes'. + * If the option does not exist, it will be created. * This function is designed to work with or without a logged-in user. In terms of security, * plugin developers should check the current user's capabilities before updating any options.