File tree Expand file tree Collapse file tree 1 file changed +2
-20
lines changed Expand file tree Collapse file tree 1 file changed +2
-20
lines changed Original file line number Diff line number Diff line change @@ -111,24 +111,6 @@ export function useDocument<T>(
111111 * @param database - name of the database
112112 * @returns the Firestore instance
113113 */
114- export function useFirestore ( database : string ) : Firestore
115- export function useFirestore ( options : {
116- name ?: string
117- database ?: string
118- } ) : Firestore
119- export function useFirestore (
120- optionsOrDatabase : string | { name ?: string ; database ?: string }
121- ) : Firestore {
122- if ( typeof optionsOrDatabase === 'string' ) {
123- return getFirestore ( useFirebaseApp ( ) , optionsOrDatabase )
124- }
125-
126- if ( optionsOrDatabase . database ) {
127- return getFirestore (
128- useFirebaseApp ( optionsOrDatabase . name ) ,
129- optionsOrDatabase . database
130- )
131- }
132-
133- return getFirestore ( useFirebaseApp ( optionsOrDatabase . name ) )
114+ export function useFirestore ( name ?: string , database ?: string ) : Firestore {
115+ return getFirestore ( useFirebaseApp ( name ) , database )
134116}
You can’t perform that action at this time.
0 commit comments