From 2f4cd0931786cb6268dd129bc4777a93ae674aa4 Mon Sep 17 00:00:00 2001 From: Hengchang Lu <44047106+luhc228@users.noreply.github.com> Date: Thu, 3 Jun 2021 16:12:28 +0800 Subject: [PATCH] fix: upload app (#22) * fix: upload app * fix: comment --- scripts/uploadApp.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/scripts/uploadApp.ts b/scripts/uploadApp.ts index 83efdc7..e194359 100644 --- a/scripts/uploadApp.ts +++ b/scripts/uploadApp.ts @@ -41,7 +41,9 @@ const { build: { productName }, version } = packageJSON; { ossObjectFile: packageWithVersionFile, localFile: packageWithVersionFile }, { ossObjectFile: packageZipFile, localFile: packageZipFile }, ]; - Promise.all([ - fileLists.map(({ ossObjectFile, localFile }) => uploadToOSS(`${OSSObjectDir}/${ossObjectFile}`, path.join(buildResourcesDir, localFile))), - ]); + await Promise.all( + fileLists.map(({ ossObjectFile, localFile }) => { + return uploadToOSS(`${OSSObjectDir}/${ossObjectFile}`, path.join(buildResourcesDir, localFile)); + }), + ); })();