You are here

public function TokenAuthUser::getChangedTimeAcrossTranslations in Simple OAuth (OAuth2) & OpenID Connect 8.4

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

Gets the timestamp of the last entity change across all translations.

This method will return the highest timestamp across all translations. To check that no translation is older than in another version of the entity (e.g. to avoid overwriting newer translations with old data), compare each translation to the other version individually.

Return value

int The timestamp of the last entity save operation across all translations.

Overrides EntityChangedInterface::getChangedTimeAcrossTranslations

File

src/Authentication/TokenAuthUser.php, line 251

Class

TokenAuthUser
The decorated user class with token information.

Namespace

Drupal\simple_oauth\Authentication

Code

public function getChangedTimeAcrossTranslations() {
  return $this->subject
    ->getChangedTimeAcrossTranslations();
}