File tree 2 files changed +3
-5
lines changed
2 files changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -20,8 +20,8 @@ export interface FirebaseAppCheckInternal {
20
20
// is present. Returns null if no token is present and no token requests are in-flight.
21
21
getToken ( forceRefresh ?: boolean ) : Promise < AppCheckTokenResult > ;
22
22
23
- // Gets a limited use Firebase App Check token. This method should be used
24
- // only if you need to authorize requests to a non-Firebase backend .
23
+ // Always returns a fresh limited- use token suitable for Replay Protection.
24
+ // The returned token must be used and consumed as soon as possible .
25
25
getLimitedUseToken ( ) : Promise < AppCheckTokenResult > ;
26
26
27
27
// Registers a listener to changes in the token state. There can be more than one listener
Original file line number Diff line number Diff line change @@ -140,9 +140,7 @@ export class ContextProvider {
140
140
async getContext ( limitedUseAppCheckTokens ?: boolean ) : Promise < Context > {
141
141
const authToken = await this . getAuthToken ( ) ;
142
142
const messagingToken = await this . getMessagingToken ( ) ;
143
- const appCheckToken = await this . getAppCheckToken (
144
- limitedUseAppCheckTokens
145
- ) ;
143
+ const appCheckToken = await this . getAppCheckToken ( limitedUseAppCheckTokens ) ;
146
144
return { authToken, messagingToken, appCheckToken } ;
147
145
}
148
146
}
You can’t perform that action at this time.
0 commit comments