@@ -54,7 +54,7 @@ export const enum HttpHeader {
5454 X_FIREBASE_APP_CHECK = 'X-Firebase-AppCheck'
5555}
5656
57- export enum Endpoint {
57+ export const enum Endpoint {
5858 CREATE_AUTH_URI = '/v1/accounts:createAuthUri' ,
5959 DELETE_ACCOUNT = '/v1/accounts:delete' ,
6060 RESET_PASSWORD = '/v1/accounts:resetPassword' ,
@@ -155,7 +155,6 @@ async function performApiRequest<T, V>(
155155 request ?: T ,
156156 customErrorMap : Partial < ServerErrorMap < ServerError > > = { }
157157) : Promise < V > {
158- _assertValidEndpointForAuth ( auth , path ) ;
159158 return _performFetchWithErrorHandling ( auth , customErrorMap , async ( ) => {
160159 let body = { } ;
161160 let params = { } ;
@@ -375,22 +374,6 @@ export function _parseEnforcementState(
375374 }
376375}
377376
378- function _assertValidEndpointForAuth (
379- auth : Auth ,
380- path : Endpoint | RegionalEndpoint
381- ) : void {
382- if (
383- ! auth . tenantConfig &&
384- Object . values ( RegionalEndpoint ) . includes ( path as RegionalEndpoint )
385- ) {
386- throw _operationNotSupportedForInitializedAuthInstance ( auth ) ;
387- }
388-
389- if ( auth . tenantConfig && Object . values ( Endpoint ) . includes ( path as Endpoint ) ) {
390- throw _operationNotSupportedForInitializedAuthInstance ( auth ) ;
391- }
392- }
393-
394377class NetworkTimeout < T > {
395378 // Node timers and browser timers are fundamentally incompatible, but we
396379 // don't care about the value here
0 commit comments