Skip to content

Commit b065e71

Browse files
committed
Use priority context when scheduling error boundary work
1 parent 930fda0 commit b065e71

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/renderers/shared/fiber/ReactFiberScheduler.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -567,10 +567,9 @@ module.exports = function<T, P, I, TI, C>(config : HostConfig<T, P, I, TI, C>) {
567567

568568
// We will process an update caused by each error boundary synchronously.
569569
affectedBoundaries.forEach(boundary => {
570-
// FIXME: We only specify LowPriority here so that setState() calls from the error
571-
// boundaries are respected. Instead we should set default priority level or something
572-
// like this. Reconsider this piece when synchronous scheduling is in place.
573-
const priority = LowPriority;
570+
const priority = priorityContext !== null ?
571+
priorityContext :
572+
defaultPriorityContext;
574573
const root = scheduleErrorBoundaryWork(boundary, priority);
575574
// This should use findNextUnitOfWork() when synchronous scheduling is implemented.
576575
let fiber = cloneFiber(root.current, priority);

0 commit comments

Comments
 (0)