Skip to content

Commit

Permalink
Fix wrong context argument to apply
Browse files Browse the repository at this point in the history
The context argument should be the array, not null.

I wrote a test that I'll include in the next PR.
  • Loading branch information
acdlite committed Feb 10, 2022
1 parent 9b5e051 commit e0af1aa
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/react-reconciler/src/ReactFiberWorkLoop.new.js
Original file line number Diff line number Diff line change
Expand Up @@ -925,7 +925,7 @@ export function queueRecoverableErrors(errors: Array<mixed>) {
workInProgressRootRecoverableErrors = errors;
} else {
workInProgressRootConcurrentErrors = workInProgressRootConcurrentErrors.push.apply(
null,
workInProgressRootConcurrentErrors,
errors,
);
}
Expand Down
2 changes: 1 addition & 1 deletion packages/react-reconciler/src/ReactFiberWorkLoop.old.js
Original file line number Diff line number Diff line change
Expand Up @@ -925,7 +925,7 @@ export function queueRecoverableErrors(errors: Array<mixed>) {
workInProgressRootRecoverableErrors = errors;
} else {
workInProgressRootConcurrentErrors = workInProgressRootConcurrentErrors.push.apply(
null,
workInProgressRootConcurrentErrors,
errors,
);
}
Expand Down

2 comments on commit e0af1aa

@acdlite
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops I pushed this to main instead of my PR branch. Embarrassing, especially because it's not correct...

@acdlite
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in 64223fe

Please sign in to comment.