Skip to content

Commit

Permalink
Don't warn about concurrent provider renders if we finished rendering
Browse files Browse the repository at this point in the history
  • Loading branch information
eps1lon committed Nov 20, 2021
1 parent fdd6c1d commit 7cf5855
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/react-reconciler/src/ReactFiberNewContext.new.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,10 @@ export function popProvider(
pop(valueCursor, providerFiber);
if (isPrimaryRenderer) {
context._currentValue = currentValue;
context._currentRenderer = null;
} else {
context._currentValue2 = currentValue;
context._currentRenderer2 = null;
}
}

Expand Down
2 changes: 2 additions & 0 deletions packages/react-reconciler/src/ReactFiberNewContext.old.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,10 @@ export function popProvider(
pop(valueCursor, providerFiber);
if (isPrimaryRenderer) {
context._currentValue = currentValue;
context._currentRenderer = null;
} else {
context._currentValue2 = currentValue;
context._currentRenderer2 = null;
}
}

Expand Down

0 comments on commit 7cf5855

Please sign in to comment.