WP_Customize_Manager::get_lock_user_data( int $user_id )

Get lock user data.


Description Description


Parameters Parameters

$user_id

(int) (Required) User ID.


Top ↑

Return Return

(array|null) User data formatted for client.


Top ↑

Source Source

File: wp-includes/class-wp-customize-manager.php

	protected function get_lock_user_data( $user_id ) {
		if ( ! $user_id ) {
			return null;
		}
		$lock_user = get_userdata( $user_id );
		if ( ! $lock_user ) {
			return null;
		}
		return array(
			'id'     => $lock_user->ID,
			'name'   => $lock_user->display_name,
			'avatar' => get_avatar_url( $lock_user->ID, array( 'size' => 128 ) ),
		);
	}

Top ↑

Changelog Changelog

Changelog
Version Description
4.9.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.