File tree Expand file tree Collapse file tree
packages/react-reconciler/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1034,7 +1034,11 @@ function renderRoot(
10341034 hasNotProcessedNewUpdates &&
10351035 ! isSync &&
10361036 // do not delay if we're inside an act() scope
1037- ! ( flushSuspenseFallbacksInTests && IsThisRendererActing . current )
1037+ ! (
1038+ __DEV__ &&
1039+ flushSuspenseFallbacksInTests &&
1040+ IsThisRendererActing . current
1041+ )
10381042 ) {
10391043 // If we have not processed any new updates during this pass, then this is
10401044 // either a retry of an existing fallback state or a hidden tree.
@@ -1075,7 +1079,11 @@ function renderRoot(
10751079 if (
10761080 ! isSync &&
10771081 // do not delay if we're inside an act() scope
1078- ! ( flushSuspenseFallbacksInTests && IsThisRendererActing . current )
1082+ ! (
1083+ __DEV__ &&
1084+ flushSuspenseFallbacksInTests &&
1085+ IsThisRendererActing . current
1086+ )
10791087 ) {
10801088 // We're suspended in a state that should be avoided. We'll try to avoid committing
10811089 // it for as long as the timeouts let us.
@@ -1148,7 +1156,11 @@ function renderRoot(
11481156 if (
11491157 ! isSync &&
11501158 // do not delay if we're inside an act() scope
1151- ! ( flushSuspenseFallbacksInTests && IsThisRendererActing . current ) &&
1159+ ! (
1160+ __DEV__ &&
1161+ flushSuspenseFallbacksInTests &&
1162+ IsThisRendererActing . current
1163+ ) &&
11521164 workInProgressRootLatestProcessedExpirationTime !== Sync &&
11531165 workInProgressRootCanSuspendUsingConfig !== null
11541166 ) {
You can’t perform that action at this time.
0 commit comments