mirror of
https://github.com/terribleplan/next.js.git
synced 2024-01-19 02:48:18 +00:00
Prevent flooding when an error occurs (#2351)
This commit is contained in:
parent
3e7ca1e89e
commit
a07c7c448b
|
@ -42,8 +42,10 @@ ReactReconciler.mountComponent = function (...args) {
|
|||
try {
|
||||
return originalMountComponent(...args)
|
||||
} catch (err) {
|
||||
next.renderError(err)
|
||||
err.abort = true
|
||||
if (!err.abort) {
|
||||
next.renderError(err)
|
||||
err.abort = true
|
||||
}
|
||||
throw err
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue