mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2025-10-16 12:05:38 +00:00
Docs: Clarify return descriptions in the DocBlocks for set_user_setting() and delete_user_setting().
See [32613]. See #30989. git-svn-id: https://develop.svn.wordpress.org/trunk@37264 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
bb365a5dc6
commit
f5d4eb7dd3
@ -844,13 +844,14 @@ function get_user_setting( $name, $default = false ) {
|
||||
* Add or update user interface setting.
|
||||
*
|
||||
* Both $name and $value can contain only ASCII letters, numbers and underscores.
|
||||
*
|
||||
* This function has to be used before any output has started as it calls setcookie().
|
||||
*
|
||||
* @since 2.8.0
|
||||
*
|
||||
* @param string $name The name of the setting.
|
||||
* @param string $value The value for the setting.
|
||||
* @return bool|void true if set successfully/false if not.
|
||||
* @return bool|null True if set successfully, false if not. Null if the current user can't be established.
|
||||
*/
|
||||
function set_user_setting( $name, $value ) {
|
||||
if ( headers_sent() ) {
|
||||
@ -867,12 +868,13 @@ function set_user_setting( $name, $value ) {
|
||||
* Delete user interface settings.
|
||||
*
|
||||
* Deleting settings would reset them to the defaults.
|
||||
*
|
||||
* This function has to be used before any output has started as it calls setcookie().
|
||||
*
|
||||
* @since 2.7.0
|
||||
*
|
||||
* @param string $names The name or array of names of the setting to be deleted.
|
||||
* @return bool|void true if deleted successfully/false if not.
|
||||
* @return bool|null True if deleted successfully, false if not. Null if the current user can't be established.
|
||||
*/
|
||||
function delete_user_setting( $names ) {
|
||||
if ( headers_sent() ) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user