get_user_to_edit() – Retrieve user data and filter it.

You appear to be a bot. Output may be restricted

Description

Retrieve user data and filter it.

Usage

$WP_User|false = get_user_to_edit( $user_id );

Parameters

$user_id
( int ) required – User ID.

Returns

WP_User|false WP_User object on success, false on failure.

Source

File name: wordpress/wp-admin/includes/user.php
Lines:

1 to 9 of 9
function get_user_to_edit( $user_id ) {
  $user = get_userdata( $user_id );

  if ( $user ) {
    $user->filter = 'edit';
  }

  return $user;
}
 

 View on GitHub View on Trac