summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDennis Kobert <dennis@kobert.dev>2020-02-12 23:25:03 +0000
committerDennis Kobert <dennis@kobert.dev>2020-02-12 23:25:03 +0000
commit478f2d1325a26d4df5db5b215136f8904af06598 (patch)
tree841fe9c2fa0fad877ccc3673db804d559d944ea9
parent2f6ae0fcaa70d7bbcc527947197ffda1dc16b745 (diff)
Actually show the error
-rw-r--r--dist/callback.html2
1 files changed, 1 insertions, 1 deletions
diff --git a/dist/callback.html b/dist/callback.html
index 6960d81..2cc891c 100644
--- a/dist/callback.html
+++ b/dist/callback.html
@@ -22,8 +22,8 @@
fetch("https://kobert.dev/spotify-api/callback/" + token + "/" + getParameterByName("code"))
.then(function(response) {
if (!response.ok) {
- throw new Error(`HTTP error! status: ${response.status}`);
document.getElementById("p1").innerHTML = "Error occured while loading songs: ${response.status}";
+ throw new Error(`HTTP error! status: ${response.status}`);
}
document.getElementById("p1").innerHTML = "Loaded songs";
});