mirror of
https://github.com/linux-odyssey/linux-odyssey.git
synced 2026-11-05 19:20:12 +08:00
fix: disable guest login
This commit is contained in:
1 parent
3106ae00d0
commit
9ffcd9fa90
3 files changed
+13
-14
No files matched your search
@@ -87,15 +87,16 @@ const handleChange = () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const registerGuest = async () => {
|
// Guest account currently disabled
|
||||||
try {
|
// const registerGuest = async () => {
|
||||||
await api.post('/auth/register-guest')
|
// try {
|
||||||
router.push({ name: 'map' })
|
// await api.post('/auth/register-guest')
|
||||||
} catch (err) {
|
// router.push({ name: 'map' })
|
||||||
console.error(err)
|
// } catch (err) {
|
||||||
toast.error('Something went wrong.')
|
// console.error(err)
|
||||||
}
|
// toast.error('Something went wrong.')
|
||||||
}
|
// }
|
||||||
|
// }
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
<!-- login page -->
|
<!-- login page -->
|
||||||
@@ -241,13 +242,13 @@ const registerGuest = async () => {
|
|||||||
</RouterLink></span
|
</RouterLink></span
|
||||||
>
|
>
|
||||||
</p>
|
</p>
|
||||||
<button
|
<!-- <button
|
||||||
id="register-guest"
|
id="register-guest"
|
||||||
class="rounded-lg py-2 mt-3 bg-bg-primary text-text-secondary w-full border-text-secondary border-2"
|
class="rounded-lg py-2 mt-3 bg-bg-primary text-text-secondary w-full border-text-secondary border-2"
|
||||||
@click="registerGuest()"
|
@click="registerGuest()"
|
||||||
>
|
>
|
||||||
{{ t('authform.continue_as_guest') }}
|
{{ t('authform.continue_as_guest') }}
|
||||||
</button>
|
</button> -->
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -1,4 +1,3 @@
|
|||||||
version: '3'
|
|
||||||
services:
|
services:
|
||||||
traefik:
|
traefik:
|
||||||
image: traefik:v3.6.9
|
image: traefik:v3.6.9
|
||||||
@@ -22,7 +21,6 @@ services:
|
|||||||
|
|
||||||
db:
|
db:
|
||||||
image: mongo:6
|
image: mongo:6
|
||||||
restart: always
|
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
ports:
|
ports:
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ async function recordLogin(req: Request, success: boolean, message: string) {
|
|||||||
|
|
||||||
router.post('/register', authenticateRateLimit, registerValidators, register)
|
router.post('/register', authenticateRateLimit, registerValidators, register)
|
||||||
|
|
||||||
router.post('/register-guest', authenticateRateLimit, registerGuest)
|
// router.post('/register-guest', authenticateRateLimit, registerGuest)
|
||||||
|
|
||||||
router.post('/logout', logout)
|
router.post('/logout', logout)
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user