Update componentDidCatch argument name like demo (#2180)

This commit is contained in:
Behnam Mohammadi
2019-08-12 11:37:53 +04:30
committed by Alexey Pyltsyn
parent 176e85f4d5
commit 8cd5737ba1

View File

@@ -36,9 +36,9 @@ class ErrorBoundary extends React.Component {
return { hasError: true };
}
componentDidCatch(error, info) {
componentDidCatch(error, errorInfo) {
// You can also log the error to an error reporting service
logErrorToMyService(error, info);
logErrorToMyService(error, errorInfo);
}
render() {