diff --git a/packages/nuxt/src/app/composables/error.ts b/packages/nuxt/src/app/composables/error.ts index e50c8b7250..729ded637d 100644 --- a/packages/nuxt/src/app/composables/error.ts +++ b/packages/nuxt/src/app/composables/error.ts @@ -10,7 +10,6 @@ export interface NuxtError extends H3Error {} export const showError = (_err: string | Error | Partial) => { const err = createError(_err) - err.fatal = true try { const nuxtApp = useNuxtApp() diff --git a/packages/nuxt/src/pages/runtime/router.ts b/packages/nuxt/src/pages/runtime/router.ts index 34502c4885..190ad20cc7 100644 --- a/packages/nuxt/src/pages/runtime/router.ts +++ b/packages/nuxt/src/pages/runtime/router.ts @@ -165,6 +165,7 @@ export default defineNuxtPlugin(async (nuxtApp) => { if (to.matched.length === 0) { callWithNuxt(nuxtApp, showError, [createError({ statusCode: 404, + fatal: false, statusMessage: `Page not found: ${to.fullPath}` })]) } else if (process.server && to.matched[0].name === '404' && nuxtApp.ssrContext) {