2022-11-13 14:34:43 +09:00
|
|
|
<script setup lang="ts">
|
2022-11-14 23:54:30 +09:00
|
|
|
const token = useCookie('nuxtodon-token')
|
|
|
|
const router = useRouter()
|
2022-11-15 22:50:41 +09:00
|
|
|
|
2022-11-15 20:54:07 +09:00
|
|
|
// TODO: move to middleware
|
2022-11-14 23:54:30 +09:00
|
|
|
if (!token.value)
|
|
|
|
router.replace('/public')
|
2022-11-15 22:50:41 +09:00
|
|
|
else
|
|
|
|
router.replace('/home')
|
2022-11-13 14:34:43 +09:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<template>
|
2022-11-15 22:50:41 +09:00
|
|
|
<div />
|
2022-11-13 14:34:43 +09:00
|
|
|
</template>
|