Remove unreachable code (#13762)

This commit is contained in:
Heaven
2018-10-03 18:03:01 -06:00
committed by Andrew Clark
parent 36c5d69caa
commit 5c783ee751
-11
View File
@@ -929,23 +929,12 @@ function completeUnitOfWork(workInProgress: Fiber): Fiber | null {
nextRenderExpirationTime,
);
}
let next = nextUnitOfWork;
stopWorkTimer(workInProgress);
resetChildExpirationTime(workInProgress, nextRenderExpirationTime);
if (__DEV__) {
ReactCurrentFiber.resetCurrentFiber();
}
if (next !== null) {
stopWorkTimer(workInProgress);
if (__DEV__ && ReactFiberInstrumentation.debugTool) {
ReactFiberInstrumentation.debugTool.onCompleteWork(workInProgress);
}
// If completing this work spawned new work, do that next. We'll come
// back here again.
return next;
}
if (
returnFiber !== null &&
// Do not append effects to parents if a sibling failed to complete