File tree Expand file tree Collapse file tree 3 files changed +5
-6
lines changed Expand file tree Collapse file tree 3 files changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -1773,7 +1773,7 @@ declare namespace firebase.remoteConfig {
1773
1773
*/
1774
1774
export type LogLevel = 'debug' | 'error' | 'silent' ;
1775
1775
/**
1776
- * An async function that returns true if current browser context supports initialization of remote config module
1776
+ * Returns true if current browser context supports initialization of remote config module
1777
1777
* (`firebase.remoteConfig()`).
1778
1778
*
1779
1779
* Returns false otherwise.
Original file line number Diff line number Diff line change @@ -77,7 +77,7 @@ export function registerRemoteConfig(
77
77
}
78
78
// Guards against the SDK being used when indexedDB is not available.
79
79
if ( ! isIndexedDBAvailable ( ) ) {
80
- throw ERROR_FACTORY . create ( ErrorCode . INDEXED_DB_UNSUPPORTED ) ;
80
+ throw ERROR_FACTORY . create ( ErrorCode . INDEXED_DB_UNAVAILABLE ) ;
81
81
}
82
82
// Normalizes optional inputs.
83
83
const { projectId, apiKey, appId } = app . options ;
@@ -159,8 +159,7 @@ async function isSupported(): Promise<boolean> {
159
159
}
160
160
161
161
try {
162
- const isDBOpenable : boolean = await validateIndexedDBOpenable ( ) ;
163
- return isDBOpenable ;
162
+ return await validateIndexedDBOpenable ( ) ;
164
163
} catch ( error ) {
165
164
return false ;
166
165
}
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ export const enum ErrorCode {
31
31
FETCH_THROTTLE = 'fetch-throttle' ,
32
32
FETCH_PARSE = 'fetch-client-parse' ,
33
33
FETCH_STATUS = 'fetch-status' ,
34
- INDEXED_DB_UNSUPPORTED = 'indexed-db-unsupported '
34
+ INDEXED_DB_UNAVAILABLE = 'indexed-db-unavailable '
35
35
}
36
36
37
37
const ERROR_DESCRIPTION_MAP : { readonly [ key in ErrorCode ] : string } = {
@@ -66,7 +66,7 @@ const ERROR_DESCRIPTION_MAP: { readonly [key in ErrorCode]: string } = {
66
66
' Original error: {$originalErrorMessage}.' ,
67
67
[ ErrorCode . FETCH_STATUS ] :
68
68
'Fetch server returned an HTTP error status. HTTP status: {$httpStatus}.' ,
69
- [ ErrorCode . INDEXED_DB_UNSUPPORTED ] :
69
+ [ ErrorCode . INDEXED_DB_UNAVAILABLE ] :
70
70
'Indexed DB is not supported by current browser'
71
71
} ;
72
72
You can’t perform that action at this time.
0 commit comments