File tree Expand file tree Collapse file tree 5 files changed +7
-12
lines changed Expand file tree Collapse file tree 5 files changed +7
-12
lines changed Original file line number Diff line number Diff line change @@ -1734,7 +1734,6 @@ function onDelete() {
1734
1734
var isAppleProviderLinked = false ;
1735
1735
1736
1736
for ( const provider of activeUser ( ) . providerData ) {
1737
- console . log ( 'provider.providerId: ' + provider . providerId ) ;
1738
1737
if ( provider . providerId == 'apple.com' ) {
1739
1738
isAppleProviderLinked = true ;
1740
1739
break ;
@@ -1761,7 +1760,6 @@ function revokeAppleTokenAndDeleteUser() {
1761
1760
provider . addScope ( 'name' ) ;
1762
1761
1763
1762
const auth = getAuth ( ) ;
1764
- // TODO: Make this pop up or redirect. Can't use signInWithPopupRedirect because we need `then`.
1765
1763
signInWithPopup ( auth , provider ) . then ( result => {
1766
1764
// The signed-in user info.
1767
1765
const user = result . user ;
Original file line number Diff line number Diff line change @@ -21,11 +21,11 @@ import chaiAsPromised from 'chai-as-promised';
21
21
22
22
import { FirebaseError , getUA , querystringDecode } from '@firebase/util' ;
23
23
24
- import { HttpHeader } from '../' ;
24
+ import { Endpoint , HttpHeader } from '../' ;
25
25
import { testAuth , TestAuth } from '../../../test/helpers/mock_auth' ;
26
26
import * as fetch from '../../../test/helpers/mock_fetch' ;
27
27
import { ServerError } from '../errors' ;
28
- import { Path , requestStsToken } from './token' ;
28
+ import { requestStsToken } from './token' ;
29
29
import { SDK_VERSION } from '@firebase/app' ;
30
30
import { _getBrowserName } from '../../core/util/browser' ;
31
31
@@ -38,7 +38,7 @@ describe('requestStsToken', () => {
38
38
beforeEach ( async ( ) => {
39
39
auth = await testAuth ( ) ;
40
40
const { apiKey, tokenApiHost, apiScheme } = auth . config ;
41
- endpoint = `${ apiScheme } ://${ tokenApiHost } ${ Path . TOKEN } ?key=${ apiKey } ` ;
41
+ endpoint = `${ apiScheme } ://${ tokenApiHost } ${ Endpoint . TOKEN } ?key=${ apiKey } ` ;
42
42
fetch . setUp ( ) ;
43
43
} ) ;
44
44
Original file line number Diff line number Diff line change @@ -32,10 +32,6 @@ import { FetchProvider } from '../../core/util/fetch_provider';
32
32
import { Auth } from '../../model/public_types' ;
33
33
import { AuthInternal } from '../../model/auth' ;
34
34
35
- export const enum Path {
36
- TOKEN = '/v1/token'
37
- }
38
-
39
35
export const enum TokenType {
40
36
UNSPECIFIED = 'TOKEN_TYPE_UNSPECIFIED' ,
41
37
REFRESH_TOKEN = 'REFRESH_TOKEN' ,
@@ -83,7 +79,7 @@ export async function requestStsToken(
83
79
const url = _getFinalTarget (
84
80
auth ,
85
81
tokenApiHost ,
86
- Path . TOKEN ,
82
+ Endpoint . TOKEN ,
87
83
`key=${ apiKey } `
88
84
) ;
89
85
Original file line number Diff line number Diff line change @@ -69,6 +69,7 @@ export const enum Endpoint {
69
69
GET_PROJECT_CONFIG = '/v1/projects' ,
70
70
GET_RECAPTCHA_CONFIG = '/v2/recaptchaConfig' ,
71
71
GET_PASSWORD_POLICY = '/v2/passwordPolicy' ,
72
+ TOKEN = '/v1/token' ,
72
73
REVOKE_TOKEN = '/v2/accounts:revokeToken'
73
74
}
74
75
Original file line number Diff line number Diff line change @@ -23,11 +23,11 @@ import { FirebaseError } from '@firebase/util';
23
23
24
24
import { testAuth , TestAuth } from '../../../test/helpers/mock_auth' ;
25
25
import * as fetch from '../../../test/helpers/mock_fetch' ;
26
- import { Path } from '../../api/authentication/token' ;
27
26
import { IdTokenResponse } from '../../model/id_token' ;
28
27
import { StsTokenManager , Buffer } from './token_manager' ;
29
28
import { FinalizeMfaResponse } from '../../api/authentication/mfa' ;
30
29
import { makeJWT } from '../../../test/helpers/jwt' ;
30
+ import { Endpoint } from '../../api' ;
31
31
32
32
use ( chaiAsPromised ) ;
33
33
@@ -103,7 +103,7 @@ describe('core/user/token_manager', () => {
103
103
let mock : fetch . Route ;
104
104
beforeEach ( ( ) => {
105
105
const { apiKey, tokenApiHost, apiScheme } = auth . config ;
106
- const endpoint = `${ apiScheme } ://${ tokenApiHost } ${ Path . TOKEN } ?key=${ apiKey } ` ;
106
+ const endpoint = `${ apiScheme } ://${ tokenApiHost } ${ Endpoint . TOKEN } ?key=${ apiKey } ` ;
107
107
mock = fetch . mock ( endpoint , {
108
108
'access_token' : 'new-access-token' ,
109
109
'refresh_token' : 'new-refresh-token' ,
You can’t perform that action at this time.
0 commit comments