From 8e9676ce3bd07636c2214af3dafc9ac83aedeabf Mon Sep 17 00:00:00 2001 From: Camila Espinoza <56554983+cami-espinozaq@users.noreply.github.com> Date: Thu, 23 Nov 2023 12:25:37 +0100 Subject: [PATCH] Update project-save-hoc.jsx - error logs --- src/lib/project-save-hoc.jsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/lib/project-save-hoc.jsx b/src/lib/project-save-hoc.jsx index dfddb5b5c..2ff354388 100644 --- a/src/lib/project-save-hoc.jsx +++ b/src/lib/project-save-hoc.jsx @@ -76,6 +76,7 @@ const ProjectSaveHOC = (WrappedComponent) => { await this.saveMeta() } catch (e) { if (!this.requestCancelSave) { + console.log("error save:", e) errPromise = this.setError('Das hat leider nicht geklappt') } else { errPromise = Promise.reject() @@ -91,6 +92,8 @@ const ProjectSaveHOC = (WrappedComponent) => { } saveAssets() { + console.log("inside save assets") + const costumeAssets = serializeCostumes(this.props.vm.runtime) const soundAssets = serializeSounds(this.props.vm.runtime) return Promise.all( @@ -107,6 +110,9 @@ const ProjectSaveHOC = (WrappedComponent) => { filename: asset.fileName, }), }) + + console.log("save assets res", res) + if (!res.ok && res.status !== 409) { throw new Error(`uploading an asset failed: ${asset.filename}`) }