Skip to content

Commit f8e40db

Browse files
author
Jacques Leupin
committed
fix: remove deprecated API
1 parent 6dcc51d commit f8e40db

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

packages/react-native/React/Fabric/RCTSurfacePresenter.mm

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -346,7 +346,7 @@ - (void)schedulerMeasure:(ReactTag)surfaceId
346346

347347
// The component view registry and UIKit measurements must be accessed on the main thread.
348348
RCTExecuteOnMainQueue(^{
349-
UIView *targetView = [self findComponentViewWithTag_DO_NOT_USE_DEPRECATED:reactTag];
349+
UIView *targetView = [self->_mountingManager.componentViewRegistry findComponentViewWithTag:reactTag];
350350
if (!targetView) {
351351
[scheduler onMeasureResultWithCallbackId:callbackId
352352
inWindow:inWindow
@@ -362,7 +362,8 @@ - (void)schedulerMeasure:(ReactTag)surfaceId
362362
if (inWindow) {
363363
rect = [targetView convertRect:targetView.bounds toView:nil];
364364
} else {
365-
UIView *rootView = [self findComponentViewWithTag_DO_NOT_USE_DEPRECATED:surfaceId];
365+
RCTFabricSurface *surface = [self surfaceForRootTag:surfaceId];
366+
UIView *rootView = surface.view;
366367
if (!rootView) {
367368
[scheduler onMeasureResultWithCallbackId:callbackId
368369
inWindow:inWindow

0 commit comments

Comments
 (0)