fix: disable guest login

This commit is contained in:
Justin Lin committed 2026-11-03 20:18:15 +11:00
1 parent 3106ae00d0
commit 9ffcd9fa90
3 files changed
+13 -14

No files matched your search

+12 -11
View File
@@ -87,15 +87,16 @@ const handleChange = () => {
}
}
const registerGuest = async () => {
try {
await api.post('/auth/register-guest')
router.push({ name: 'map' })
} catch (err) {
console.error(err)
toast.error('Something went wrong.')
}
}
// Guest account currently disabled
// const registerGuest = async () => {
// try {
// await api.post('/auth/register-guest')
// router.push({ name: 'map' })
// } catch (err) {
// console.error(err)
// toast.error('Something went wrong.')
// }
// }
</script>
<template>
<!-- login page -->
@@ -241,13 +242,13 @@ const registerGuest = async () => {
</RouterLink></span
>
</p>
<button
<!-- <button
id="register-guest"
class="rounded-lg py-2 mt-3 bg-bg-primary text-text-secondary w-full border-text-secondary border-2"
@click="registerGuest()"
>
{{ t('authform.continue_as_guest') }}
</button>
</button> -->
</form>
</div>
</template>
-2
View File
@@ -1,4 +1,3 @@
version: '3'
services:
traefik:
image: traefik:v3.6.9
@@ -22,7 +21,6 @@ services:
db:
image: mongo:6
restart: always
networks:
- internal
ports:
+1 -1
View File
@@ -73,7 +73,7 @@ async function recordLogin(req: Request, success: boolean, message: string) {
router.post('/register', authenticateRateLimit, registerValidators, register)
router.post('/register-guest', authenticateRateLimit, registerGuest)
// router.post('/register-guest', authenticateRateLimit, registerGuest)
router.post('/logout', logout)