From ee758aa626ea7a852cb3b6bcd47d649baa4379a3 Mon Sep 17 00:00:00 2001 From: Leo Lee Date: Fri, 28 Oct 2022 11:17:56 +0800 Subject: [PATCH] fix: ignore queryCollection option when exporting sub-collection data --- src/export.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/export.ts b/src/export.ts index 227d0d1..200f769 100644 --- a/src/export.ts +++ b/src/export.ts @@ -142,10 +142,11 @@ export const backUpDocRef = async ( if (subCollections.length > 0) { data['subCollection'] = {} + const {queryCollection, ...subColOptions} = options; for (const subCol of subCollections) { const subColData = await backupService( `${collectionPath}/${doc.id}/${subCol.id}`, - options + subColOptions ) data['subCollection'] = {