You are here

public function ExpiredCollector::deleteMultipleTokens in Simple OAuth (OAuth2) & OpenID Connect 5.x

Same name and namespace in other branches
  1. 8.4 src/ExpiredCollector.php \Drupal\simple_oauth\ExpiredCollector::deleteMultipleTokens()
  2. 8.2 src/ExpiredCollector.php \Drupal\simple_oauth\ExpiredCollector::deleteMultipleTokens()
  3. 8.3 src/ExpiredCollector.php \Drupal\simple_oauth\ExpiredCollector::deleteMultipleTokens()

Deletes multiple tokens based on ID.

Parameters

\Drupal\simple_oauth\Entity\Oauth2TokenInterface[] $tokens: The token entity IDs.

File

src/ExpiredCollector.php, line 141

Class

ExpiredCollector
Service in charge of deleting or expiring tokens that cannot be used anymore.

Namespace

Drupal\simple_oauth

Code

public function deleteMultipleTokens(array $tokens = []) {
  $this->tokenStorage
    ->delete($tokens);
}