From bd42ec677e99ee33905382701189b1b5768a75a7 Mon Sep 17 00:00:00 2001 From: George Mamadashvili Date: Mon, 9 Aug 2021 08:47:47 +0400 Subject: [PATCH] Try componentDidCatch --- packages/edit-site/src/components/error-boundary/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/edit-site/src/components/error-boundary/index.js b/packages/edit-site/src/components/error-boundary/index.js index e425df492405f3..fc69405c3372b8 100644 --- a/packages/edit-site/src/components/error-boundary/index.js +++ b/packages/edit-site/src/components/error-boundary/index.js @@ -27,8 +27,8 @@ export default class ErrorBoundary extends Component { }; } - static getDerivedStateFromError( error ) { - return { error }; + componentDidCatch( error ) { + this.setState( { error } ); } reboot() {