fix(nuxt): do not render page if we are throwing error (#8821)

This commit is contained in:
Daniel Roe 2022-11-09 10:08:37 +01:00 committed by GitHub
parent 4d1be089d7
commit 5a32927935
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -157,7 +157,8 @@ export default defineNuxtPlugin(async (nuxtApp) => {
statusCode: 404,
statusMessage: `Page Not Found: ${initialURL}`
})
return callWithNuxt(nuxtApp, showError, [error])
await callWithNuxt(nuxtApp, showError, [error])
return false
}
}
if (result || result === false) { return result }