You are here

public static function Reference::getCurrentUserId in Bibliography & Citation 8

Same name and namespace in other branches
  1. 2.0.x modules/bibcite_entity/src/Entity/Reference.php \Drupal\bibcite_entity\Entity\Reference::getCurrentUserId()

Default value callback for 'uid' base field definition.

Return value

array An array of default values.

See also

::baseFieldDefinitions()

File

modules/bibcite_entity/src/Entity/Reference.php, line 429

Class

Reference
Defines the Reference entity.

Namespace

Drupal\bibcite_entity\Entity

Code

public static function getCurrentUserId() {
  return [
    \Drupal::currentUser()
      ->id(),
  ];
}