diff --git a/packages/nuxt/src/core/runtime/nitro/renderer.ts b/packages/nuxt/src/core/runtime/nitro/renderer.ts index a5c2c89a2d..cbba99e7c8 100644 --- a/packages/nuxt/src/core/runtime/nitro/renderer.ts +++ b/packages/nuxt/src/core/runtime/nitro/renderer.ts @@ -251,7 +251,7 @@ export default defineRenderHandler(async (event): Promise { console.warn('Unhead has fallen back to a shared context that may have unexpected behavior. Consider wrapping your code with nuxtApp.runWithContext. Learn more at https://nuxt.com/docs/getting-started/seo-meta#pitfalls.') // dump stacktrace to help debugging, we don't want to trigger a blocking SSR error - console.warn(new Error().stack!.split('\n').slice(5).join('\n')) + console.warn(new Error('').stack!.split('\n').slice(5).join('\n')) }) } // needed for hash hydration plugin to work