@samitouri / QOS-React / commits / 9503abe5c7

Pass errorBoundary to logCapturedError (#9050)

Ben Alpert committed Feb 22, 2017 at 13:06 UTC 9503abe5c700d0d3be76b45e7841e44ba2eab3ba
1 file changed +3 -1
src/renderers/shared/fiber/ReactFiberScheduler.js
+3 -1
@@ -21,6 +21,7 @@ export type CapturedError = {
21 componentName : ?string,
22 componentStack : string,
23 error : Error,
24 + errorBoundary : ?Object,
25 errorBoundaryFound : boolean,
26 errorBoundaryName : string | null,
27 willRetry : boolean,
@@ -762,7 +763,7 @@ module.exports = function<T, P, I, TI, PI, C, CX, PL>(config : HostConfig<T, P,
763 } catch (error) {
764 // We caught an error during either the begin or complete phases.
765 const failedWork = nextUnitOfWork;
765 -
766 +
767 if (failedWork !== null) {
768 // Reset the priority context to its value before reconciliation.
769 priorityContext = priorityContextBeforeReconciliation;
@@ -957,6 +958,7 @@ module.exports = function<T, P, I, TI, PI, C, CX, PL>(config : HostConfig<T, P,
958 componentName,
959 componentStack,
960 error,
961 + errorBoundary: errorBoundaryFound ? boundary.stateNode : null,
962 errorBoundaryFound,
963 errorBoundaryName,
964 willRetry,