Skip to content

Commit

Permalink
Remove debug stack dedupe handling (not needed)
Browse files Browse the repository at this point in the history
  • Loading branch information
unstubbable committed Sep 23, 2024
1 parent 8fea0ca commit 3f9a7c3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 13 deletions.
14 changes: 4 additions & 10 deletions packages/react-client/src/ReactFlightClient.js
Original file line number Diff line number Diff line change
Expand Up @@ -947,7 +947,7 @@ function waitForReference<T>(
}

// If the parent object is an unparsed React element tuple, we also need to
// update the props, owner, and stack of the parsed element object (i.e.
// update the props and owner of the parsed element object (i.e.
// handler.value).
if (
parentObject[0] === REACT_ELEMENT_TYPE &&
Expand All @@ -961,15 +961,9 @@ function waitForReference<T>(
element.props = mappedValue;
break;
case '4':
element._owner = mappedValue;
break;
case '5':
Object.defineProperty(element, '_debugStack', {
configurable: false,
enumerable: false,
writable: true,
value: mappedValue,
});
if (__DEV__) {
element._owner = mappedValue;
}
break;
}
}
Expand Down
3 changes: 0 additions & 3 deletions packages/react-server/src/ReactFlightServer.js
Original file line number Diff line number Diff line change
Expand Up @@ -2668,9 +2668,6 @@ function renderModelDestructive(
case '4':
propertyName = '_owner';
break;
case '5':
propertyName = '_debugStack';
break;
}
}
writtenObjects.set(value, parentReference + ':' + propertyName);
Expand Down

0 comments on commit 3f9a7c3

Please sign in to comment.