Skip to content

Commit 91b9705

Browse files
eps1lonSebastian Silbermann
authored andcommitted
Only need to reset in DEV since we only set in DEV
1 parent bb33098 commit 91b9705

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

packages/react-reconciler/src/ReactFiberNewContext.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,9 @@ export function popProvider(
141141
} else {
142142
context._currentValue = currentValue;
143143
}
144-
context._currentRenderer = null;
144+
if (__DEV__) {
145+
context._currentRenderer = null;
146+
}
145147
} else {
146148
if (
147149
enableServerContext &&
@@ -151,7 +153,9 @@ export function popProvider(
151153
} else {
152154
context._currentValue2 = currentValue;
153155
}
154-
context._currentRenderer2 = null;
156+
if (__DEV__) {
157+
context._currentRenderer2 = null;
158+
}
155159
}
156160
}
157161

0 commit comments

Comments
 (0)