Unverified Commit 6ca26bd9 authored by Sam Bokai's avatar Sam Bokai Committed by GitHub

Rename import to solve conflicting usage of Error constructor (#13256)

parent 94e20be2
import Error from 'next/error'
import NextErrorComponent from 'next/error'
import * as Sentry from '@sentry/node'
const MyError = ({ statusCode, hasGetInitialPropsRun, err }) => {
......@@ -9,7 +9,7 @@ const MyError = ({ statusCode, hasGetInitialPropsRun, err }) => {
Sentry.captureException(err)
}
return <Error statusCode={statusCode} />
return <NextErrorComponent statusCode={statusCode} />
}
MyError.getInitialProps = async ({ res, err, asPath }) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment