Skip to content

Commit 40cdec4

Browse files
author
Grace Benz
committed
Update types and clean up log statements
1 parent fee6150 commit 40cdec4

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

packages/firestore/src/api/credentials.ts

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export interface FirstPartyCredentialsSettings {
3434
['type']: 'gapi';
3535
['client']: unknown;
3636
['sessionIndex']: string;
37-
['iamToken']: string;
37+
['iamToken']: string | null;
3838
}
3939

4040
export interface ProviderCredentialsSettings {
@@ -296,10 +296,8 @@ export class FirstPartyToken implements Token {
296296
constructor(
297297
private gapi: Gapi,
298298
private sessionIndex: string,
299-
private iamToken: string
300-
) {
301-
console.log('bingo!! this is the token', iamToken);
302-
}
299+
private iamToken: string | null
300+
) {}
303301

304302
get authHeaders(): { [header: string]: string } {
305303
const headers: { [header: string]: string } = {
@@ -326,7 +324,7 @@ export class FirstPartyCredentialsProvider implements CredentialsProvider {
326324
constructor(
327325
private gapi: Gapi,
328326
private sessionIndex: string,
329-
private iamToken: string
327+
private iamToken: string | null
330328
) {}
331329

332330
getToken(): Promise<Token | null> {
@@ -372,7 +370,7 @@ export function makeCredentialsProvider(
372370
return new FirstPartyCredentialsProvider(
373371
client,
374372
credentials['sessionIndex'] || '0',
375-
credentials['iamToken'] || ''
373+
credentials['iamToken'] || null
376374
);
377375

378376
case 'provider':

0 commit comments

Comments
 (0)