You are here

public static function TokenAuthUser::preCreate in Simple OAuth (OAuth2) & OpenID Connect 8.2

Same name and namespace in other branches
  1. 8.4 src/Authentication/TokenAuthUser.php \Drupal\simple_oauth\Authentication\TokenAuthUser::preCreate()
  2. 8 src/Authentication/TokenAuthUser.php \Drupal\simple_oauth\Authentication\TokenAuthUser::preCreate()
  3. 8.3 src/Authentication/TokenAuthUser.php \Drupal\simple_oauth\Authentication\TokenAuthUser::preCreate()
  4. 5.x src/Authentication/TokenAuthUser.php \Drupal\simple_oauth\Authentication\TokenAuthUser::preCreate()

Changes the values of an entity before it is created.

Load defaults for example.

Parameters

\Drupal\Core\Entity\EntityStorageInterface $storage: The entity storage object.

mixed[] $values: An array of values to set, keyed by property name. If the entity type has bundles the bundle key has to be specified.

Overrides EntityInterface::preCreate

File

src/Authentication/TokenAuthUser.php, line 368

Class

TokenAuthUser
@internal

Namespace

Drupal\simple_oauth\Authentication

Code

public static function preCreate(EntityStorageInterface $storage, array &$values) {
  User::preCreate($storage, $values);
}