You are here

public function Client::getAuthState in Media: Acquia DAM 8

Get internal auth state details.

1 call to Client::getAuthState()
Client::checkAuth in src/Client.php
Authenticates with the DAM service and retrieves or uses an access token.

File

src/Client.php, line 139

Class

Client
Overridden implementation of the cweagans php-webdam-client.

Namespace

Drupal\media_acquiadam

Code

public function getAuthState() {
  $state = parent::getAuthState();
  if (!empty($state['valid_token']) && empty($state['refresh_token'])) {
    $state['refresh_token'] = $this->refreshToken;
  }
  return $state;
}