aboutsummaryrefslogtreecommitdiffstats
path: root/src/public
diff options
context:
space:
mode:
authorMatt Strapp <matt@mattstrapp.net>2022-02-24 15:43:04 -0600
committerMatt Strapp <matt@mattstrapp.net>2022-02-24 15:43:04 -0600
commitc98930b06f10d00e77e16b56afa1658f6740a224 (patch)
tree8c090ad1553f4f74fe75a36afbac56677de3a1a8 /src/public
parentFix bug with windows not uploading the right mimetype (diff)
downloadee4511w-web-c98930b06f10d00e77e16b56afa1658f6740a224.tar
ee4511w-web-c98930b06f10d00e77e16b56afa1658f6740a224.tar.gz
ee4511w-web-c98930b06f10d00e77e16b56afa1658f6740a224.tar.bz2
ee4511w-web-c98930b06f10d00e77e16b56afa1658f6740a224.tar.lz
ee4511w-web-c98930b06f10d00e77e16b56afa1658f6740a224.tar.xz
ee4511w-web-c98930b06f10d00e77e16b56afa1658f6740a224.tar.zst
ee4511w-web-c98930b06f10d00e77e16b56afa1658f6740a224.zip
Make the program not output an error when there isn't one
Signed-off-by: Matt Strapp <matt@mattstrapp.net>
Diffstat (limited to 'src/public')
-rw-r--r--src/public/js/form.js9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/public/js/form.js b/src/public/js/form.js
index 724fb05..9e926fa 100644
--- a/src/public/js/form.js
+++ b/src/public/js/form.js
@@ -57,11 +57,12 @@ function actuate(file) {
if (xhr.status === 200 || xhr.status === 500) {
createDownload(response.file);
}
- // Display upload error message to the user
- document.getElementById('actuate-err').innerText = response.error;
- // DEBUG: Print full error if unknown error occurs
- if (xhr.status === 500)
+ if (xhr.status === 500) {
+ document.getElementById('actuate-err').innerText = response.error;
+ // DEBUG: Print full error if unknown error occurs
console.error(response.error_msg);
+ }
+
}
return;
};