From 06ad6c094a2a562d767d250822c17ced85937e5a Mon Sep 17 00:00:00 2001 From: Moka Date: Sun, 27 Oct 2024 20:57:27 +0100 Subject: [PATCH] Revert "make manifest fix more future proof" This reverts commit 32591b35d0438dac99eb2ea29cd6757e3086008a. --- src/main.ts | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/main.ts b/src/main.ts index 64dde996f92..993bd1018ae 100644 --- a/src/main.ts +++ b/src/main.ts @@ -99,16 +99,13 @@ const startGame = async (manifest?: any) => { } }; -let manifest: any; fetch("/manifest.json") .then(res => res.json()) .then(jsonResponse => { - manifest = jsonResponse.manifest; - }).catch(err => { - // Manifest not found (likely local build or error path on live) - console.log(`Manifest not found. ${err}`); - }).finally(() => { - startGame(manifest); + startGame(jsonResponse.manifest); + }).catch(() => { + // Manifest not found (likely local build) + startGame(); }); export default game;