@doubling/compound-sync 1.1.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/sync.js +7 -0
package/package.json
CHANGED
package/sync.js
CHANGED
|
@@ -244,6 +244,13 @@ async function setupConfig() {
|
|
|
244
244
|
const authResult = await browserAuth(fbConfig);
|
|
245
245
|
const app = initializeApp(fbConfig, 'setup');
|
|
246
246
|
const auth = getAuth(app);
|
|
247
|
+
|
|
248
|
+
// Initialize App Check before re-authenticating in Node.js
|
|
249
|
+
const appCheckUrl = appCheckEndpoints[projectId];
|
|
250
|
+
if (appCheckUrl && authResult.firebaseIdToken) {
|
|
251
|
+
await initAppCheckWithIdToken(app, appCheckUrl, authResult.firebaseIdToken);
|
|
252
|
+
}
|
|
253
|
+
|
|
247
254
|
const db = getFirestore(app);
|
|
248
255
|
|
|
249
256
|
let userCredential;
|