add_existing_user_to_blog

Definition:
function add_existing_user_to_blog( $details = false ) {}

Add a user to a blog based on details from maybe_add_existing_user_to_blog().

Parameters

  • array $details

Defined actions

  • added_existing_user
    do_action( 'added_existing_user', $details[ 'user_id' ], $result );

Source code

function add_existing_user_to_blog( $details = false ) {

	global $blog_id;



	if ( is_array( $details ) ) {

		$result = add_user_to_blog( $blog_id, $details[ 'user_id' ], $details[ 'role' ] );

		do_action( 'added_existing_user', $details[ 'user_id' ], $result );

	}

	return $result;

}

231

No comments yet... Be the first to leave a reply!

Leave a comment