From 6c7d8e44d62f0b563be2e75c5cfe8a6433e20c83 Mon Sep 17 00:00:00 2001 From: Jack Date: Sun, 31 May 2020 21:14:21 +0100 Subject: [PATCH] added an error message when result could not be saved --- public/js/db.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/public/js/db.js b/public/js/db.js index 330cccf40..ad2a6ac08 100644 --- a/public/js/db.js +++ b/public/js/db.js @@ -11,7 +11,9 @@ function db_testCompleted(obj) { if (user) { uid = user.uid; } - db.collection('results').add(obj) + db.collection('results').add(obj).catch(e =>{ + showNotification("Error saving result! Please contact Miodec on Discord."); + }) } async function db_getUserResults() {