mirror of
https://github.com/MewoLab/AquaDX.git
synced 2026-02-09 12:37:27 +08:00
[F] More detailed error handling
This commit is contained in:
@@ -50,7 +50,7 @@
|
|||||||
if (!games[game]) {
|
if (!games[game]) {
|
||||||
// Find a valid game
|
// Find a valid game
|
||||||
const valid = Object.entries(games).filter(([g, valid]) => valid)
|
const valid = Object.entries(games).filter(([g, valid]) => valid)
|
||||||
if (!valid) return error = t("UserHome.NoValidGame")
|
if (!valid || !valid[0]) return error = t("UserHome.NoValidGame")
|
||||||
window.location.href = `/u/${username}/${valid[0][0]}`
|
window.location.href = `/u/${username}/${valid[0][0]}`
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -74,7 +74,7 @@
|
|||||||
calElement.scrollLeft = calElement.scrollWidth - calElement.clientWidth
|
calElement.scrollLeft = calElement.scrollWidth - calElement.clientWidth
|
||||||
})
|
})
|
||||||
}).catch((e) => error = e.message);
|
}).catch((e) => error = e.message);
|
||||||
}).catch((e) => error = e.message);
|
}).catch((e) => { error = e.message; console.error(e) } );
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<main id="user-home" class="content">
|
<main id="user-home" class="content">
|
||||||
|
|||||||
Reference in New Issue
Block a user