function user_label

Entity label callback.

This label callback has langcode for security reasons. The username is the visual identifier for a user and needs to be consistent in all languages.

Parameters

$entity_type: The entity type.

$entity: The entity object.

Return value

The name of the user.

See also

user_format_name()

File

drupal/core/modules/user/user.module, line 160
Enables the user registration and login system.

Code

function user_label($entity_type, $entity) {
  return user_format_name($entity
    ->getBCEntity());
}