Skip to content
Prev Previous commit
Next Next commit
fix flow
  • Loading branch information
trueadm committed Oct 12, 2018
commit e39a444a3c509f06aa718c520cd68f16a05cbda1
4 changes: 2 additions & 2 deletions packages/react-reconciler/src/ReactFiberBeginWork.js
Original file line number Diff line number Diff line change
Expand Up @@ -1112,7 +1112,7 @@ function updateContextConsumer(
// a property called "_context", which also gives us the ability to check
// in DEV mode if this property exists or not and warn if it does not.
if (__DEV__) {
if (context._context === undefined) {
if ((context: any)._context === undefined) {
if (!hasWarnedAboutUsingContextAsConsumer) {
hasWarnedAboutUsingContextAsConsumer = true;
warning(
Expand All @@ -1122,7 +1122,7 @@ function updateContextConsumer(
);
}
} else {
context = context._context;
context = (context: any)._context;
}
}
const newProps = workInProgress.pendingProps;
Expand Down