Revert "fix: i18n nuxt context error"

This reverts commit a1b73d089e.
This commit is contained in:
Michael H.
2026-08-28 16:30:32 +02:00
parent a1b73d089e
commit 0ab9100c46
+1 -4
View File
@@ -201,10 +201,7 @@ export default defineNuxtPlugin({
locale.value = newLocale
if (persist) {
// Awaiting loadLocale above drops the Nuxt context on the server, where useCookie needs it
nuxtApp.runWithContext(() => {
useCookie('locale', { maxAge: 31536000, path: '/' }).value = newLocale
})
useCookie('locale', { maxAge: 31536000, path: '/' }).value = newLocale
}
}