diff --git a/packages/react-reconciler/src/ReactFiberNewContext.new.js b/packages/react-reconciler/src/ReactFiberNewContext.new.js index 68862e568818f..74c3f5c1c513b 100644 --- a/packages/react-reconciler/src/ReactFiberNewContext.new.js +++ b/packages/react-reconciler/src/ReactFiberNewContext.new.js @@ -141,6 +141,7 @@ export function popProvider( } else { context._currentValue = currentValue; } + context._currentRenderer = null; } else { if ( enableServerContext && @@ -150,6 +151,7 @@ export function popProvider( } else { context._currentValue2 = currentValue; } + context._currentRenderer2 = null; } } diff --git a/packages/react-reconciler/src/ReactFiberNewContext.old.js b/packages/react-reconciler/src/ReactFiberNewContext.old.js index de96664e774a2..b6a3d18357eff 100644 --- a/packages/react-reconciler/src/ReactFiberNewContext.old.js +++ b/packages/react-reconciler/src/ReactFiberNewContext.old.js @@ -141,6 +141,7 @@ export function popProvider( } else { context._currentValue = currentValue; } + context._currentRenderer = null; } else { if ( enableServerContext && @@ -150,6 +151,7 @@ export function popProvider( } else { context._currentValue2 = currentValue; } + context._currentRenderer2 = null; } }