Fix logged in user stall (#1114)
This commit is contained in:
parent
4be6b11c1e
commit
d9b3ba0ff2
@ -99,13 +99,6 @@ export default defineNuxtConfig({
|
||||
type: 'font/woff2',
|
||||
crossorigin: true,
|
||||
},
|
||||
{
|
||||
rel: 'preload',
|
||||
href: 'https://cdn-raw.modrinth.com/fonts/inter/Inter-ExtraBold.woff2?v=3.19',
|
||||
as: 'font',
|
||||
type: 'font/woff2',
|
||||
crossorigin: true,
|
||||
},
|
||||
{
|
||||
rel: 'icon',
|
||||
type: 'image/x-icon',
|
||||
|
||||
@ -282,7 +282,7 @@
|
||||
Report
|
||||
</button>
|
||||
<button
|
||||
v-if="!$user.value.follows.find((x) => x.id === project.id)"
|
||||
v-if="!user.follows.find((x) => x.id === project.id)"
|
||||
class="iconified-button"
|
||||
@click="userFollowProject(project)"
|
||||
>
|
||||
@ -290,7 +290,7 @@
|
||||
Follow
|
||||
</button>
|
||||
<button
|
||||
v-if="$user.value.follows.find((x) => x.id === project.id)"
|
||||
v-if="user.follows.find((x) => x.id === project.id)"
|
||||
class="iconified-button"
|
||||
@click="userUnfollowProject(project)"
|
||||
>
|
||||
@ -747,6 +747,8 @@ import Breadcrumbs from '~/components/ui/Breadcrumbs.vue'
|
||||
const data = useNuxtApp()
|
||||
const route = useRoute()
|
||||
|
||||
const user = await useUser()
|
||||
|
||||
if (
|
||||
!route.params.id ||
|
||||
!(
|
||||
|
||||
@ -1,11 +1,10 @@
|
||||
export default defineNuxtPlugin(async (nuxtApp) => {
|
||||
const authStore = await useAuth()
|
||||
const userStore = await useUser(true)
|
||||
await useUser()
|
||||
const cosmeticsStore = useCosmetics()
|
||||
const tagsStore = useTags()
|
||||
|
||||
nuxtApp.provide('auth', authStore.value)
|
||||
nuxtApp.provide('user', userStore)
|
||||
nuxtApp.provide('cosmetics', cosmeticsStore.value)
|
||||
nuxtApp.provide('tag', tagsStore.value)
|
||||
nuxtApp.provide('notify', (notif) => addNotification(notif))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user