mirror of
https://github.com/facebook/react.git
synced 2026-11-18 20:15:56 +00:00
Clear deletions in detachFiber (#20401)
This was added in a later step of the refactor but since `deletions` array already landed, clearing it should, too. I think it's unlikely that this causes GC problems but worth adding anyway.
This commit is contained in:
1 parent
b9680aef7d
commit
7659949d65
2 files changed
+2
No files matched your search
@@ -1074,6 +1074,7 @@ function detachFiberMutation(fiber: Fiber) {
|
||||
// and one of its descendants throws while unmounting a passive effect.
|
||||
fiber.alternate = null;
|
||||
fiber.child = null;
|
||||
fiber.deletions = null;
|
||||
fiber.dependencies = null;
|
||||
fiber.firstEffect = null;
|
||||
fiber.lastEffect = null;
|
||||
|
||||
@@ -1074,6 +1074,7 @@ function detachFiberMutation(fiber: Fiber) {
|
||||
// and one of its descendants throws while unmounting a passive effect.
|
||||
fiber.alternate = null;
|
||||
fiber.child = null;
|
||||
fiber.deletions = null;
|
||||
fiber.dependencies = null;
|
||||
fiber.firstEffect = null;
|
||||
fiber.lastEffect = null;
|
||||
|
||||
Reference in new issue
Block a user