On this page
refresh_user_details( int $id ): int|false
Cleans the user cache for a specific user.
Parameters
$idint Required-
The user ID.
Return
int|false The ID of the refreshed user or false if the user does not exist.
Source
File: wp-admin/includes/ms.php. View all references
function refresh_user_details( $id ) {
$id = (int) $id;
$user = get_userdata( $id );
if ( ! $user ) {
return false;
}
clean_user_cache( $user );
return $id;
}
Related
Uses
| Uses | Description |
|---|---|
| clean_user_cache() wp-includes/user.php | Cleans all user caches. |
| get_userdata() wp-includes/pluggable.php | Retrieves user info by user ID. |
Changelog
| Version | Description |
|---|---|
| 3.0.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/refresh_user_details