Log additional information when getting auth token
This commit is contained in:
parent
bddc5ef701
commit
b77929959c
1 changed files with 3 additions and 1 deletions
|
@ -192,7 +192,9 @@ export class AzureActiveDirectoryService {
|
|||
|
||||
private async resolveAccessToken(token: IToken): Promise<string> {
|
||||
if (token.accessToken && (!token.expiresAt || token.expiresAt > Date.now())) {
|
||||
Logger.info('Token available from cache');
|
||||
token.expiresAt
|
||||
? Logger.info(`Token available from cache, expires in ${token.expiresAt - Date.now()} milliseconds`)
|
||||
: Logger.info('Token available from cache');
|
||||
return Promise.resolve(token.accessToken);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue