added_existing_user action-hookWP 3.0.0

Fires immediately after an existing user is added to a site.

Usage

add_action( 'added_existing_user', 'wp_kama_added_existing_user_action', 10, 2 );

/**
 * Function for `added_existing_user` action-hook.
 * 
 * @param int           $user_id User ID.
 * @param true|WP_Error $result  True on success or a WP_Error object if the user doesn't exist or could not be added.
 *
 * @return void
 */
function wp_kama_added_existing_user_action( $user_id, $result ){

	// action...
}
$user_id(int)
User ID.
$result(true|WP_Error)
True on success or a WP_Error object if the user doesn't exist or could not be added.

Changelog

Since 3.0.0 Introduced.

Where the hook is called

add_existing_user_to_blog()
added_existing_user
wp-includes/ms-functions.php 2239
do_action( 'added_existing_user', $details['user_id'], $result );

Where the hook is used in WordPress

Usage not found.