🥅 Improved error-handling
This commit is contained in:
@@ -62,6 +62,7 @@
|
|||||||
if (res.status !== 200) {
|
if (res.status !== 200) {
|
||||||
alert('Failed to start game!');
|
alert('Failed to start game!');
|
||||||
console.error(`Failed to start game, ${await res.text()}`);
|
console.error(`Failed to start game, ${await res.text()}`);
|
||||||
|
window.location.replace('/account/login?returnTo=/overview');
|
||||||
}
|
}
|
||||||
const data = await res.json();
|
const data = await res.json();
|
||||||
// eslint-disable-next-line no-undef
|
// eslint-disable-next-line no-undef
|
||||||
|
|||||||
Reference in New Issue
Block a user