diff --git a/packages/nuxt/src/core/runtime/nitro/error.ts b/packages/nuxt/src/core/runtime/nitro/error.ts index acb0271bb13..8c27cac531a 100644 --- a/packages/nuxt/src/core/runtime/nitro/error.ts +++ b/packages/nuxt/src/core/runtime/nitro/error.ts @@ -31,7 +31,8 @@ export default async function errorhandler (error: H3Error, '[nuxt]', '[request error]', error.unhandled && '[unhandled]', - error.fatal && '[fatal]' + error.fatal && '[fatal]', + Number(errorObject.statusCode) !== 200 && `[${errorObject.statusCode}]` ].filter(Boolean).join(' ') console.error(tags, errorObject.message + '\n' + stack.map(l => ' ' + l.text).join(' \n')) }