From d9e8fa34e7b4f513353204f7baf194c2dfb3457f Mon Sep 17 00:00:00 2001
From: David Baker <dave@matrix.org>
Date: Thu, 23 Jul 2020 11:14:26 +0100
Subject: [PATCH] Catch exceptions from main method in fetch script

---
 scripts/fetch-package.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/fetch-package.js b/scripts/fetch-package.js
index 1ee43c4..f329440 100755
--- a/scripts/fetch-package.js
+++ b/scripts/fetch-package.js
@@ -289,4 +289,4 @@ async function main() {
     console.log("Done!");
 }
 
-main().then((ret) => process.exit(ret));
+main().then((ret) => process.exit(ret)).catch(e => process.exit(1));