Skip to content

Commit e733fe6

Browse files
huntiefacebook-github-bot
authored andcommitted
Remove legacy InspectorPackagerConnection (facebook#44746)
Summary: Cleanup after this experiment's removal in D57730921. Changelog: [Internal] Reviewed By: hoxyq Differential Revision: D58017460
1 parent db1043d commit e733fe6

File tree

5 files changed

+3
-661
lines changed

5 files changed

+3
-661
lines changed

packages/react-native/React/DevSupport/RCTInspectorDevServerHelper.mm

+1-7
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414

1515
#import <React/RCTCxxInspectorPackagerConnection.h>
1616
#import <React/RCTDefines.h>
17-
#import <React/RCTInspectorPackagerConnection.h>
1817

1918
#import <CommonCrypto/CommonCrypto.h>
2019
#import <jsinspector-modern/InspectorFlags.h>
@@ -181,12 +180,7 @@ + (void)disableDebugger
181180
NSString *key = [inspectorURL absoluteString];
182181
id<RCTInspectorPackagerConnectionProtocol> connection = socketConnections[key];
183182
if (!connection || !connection.isConnected) {
184-
if (facebook::react::jsinspector_modern::InspectorFlags::getInstance().getFuseboxEnabled()) {
185-
connection = [[RCTCxxInspectorPackagerConnection alloc] initWithURL:inspectorURL];
186-
} else {
187-
// TODO(T190163403): Remove legacy RCTInspectorPackagerConnection
188-
connection = [[RCTInspectorPackagerConnection alloc] initWithURL:inspectorURL];
189-
}
183+
connection = [[RCTCxxInspectorPackagerConnection alloc] initWithURL:inspectorURL];
190184

191185
socketConnections[key] = connection;
192186
[connection connect];

packages/react-native/React/Inspector/RCTInspectorPackagerConnection.m

-325
This file was deleted.

packages/react-native/ReactAndroid/api/ReactAndroid.api

-7
Original file line numberDiff line numberDiff line change
@@ -2184,13 +2184,6 @@ public final class com/facebook/react/devsupport/InspectorFlags {
21842184
public static final fun getFuseboxEnabled ()Z
21852185
}
21862186

2187-
public class com/facebook/react/devsupport/InspectorPackagerConnection : com/facebook/react/devsupport/IInspectorPackagerConnection {
2188-
public fun <init> (Ljava/lang/String;Ljava/lang/String;)V
2189-
public fun closeQuietly ()V
2190-
public fun connect ()V
2191-
public fun sendEventToAllConnections (Ljava/lang/String;)V
2192-
}
2193-
21942187
public class com/facebook/react/devsupport/JSCHeapCapture : com/facebook/fbreact/specs/NativeJSCHeapCaptureSpec {
21952188
public fun <init> (Lcom/facebook/react/bridge/ReactApplicationContext;)V
21962189
public fun captureComplete (Ljava/lang/String;Ljava/lang/String;)V

packages/react-native/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevServerHelper.java

+2-8
Original file line numberDiff line numberDiff line change
@@ -210,14 +210,8 @@ public void openInspectorConnection() {
210210
new AsyncTask<Void, Void, Void>() {
211211
@Override
212212
protected Void doInBackground(Void... params) {
213-
if (InspectorFlags.getFuseboxEnabled()) {
214-
mInspectorPackagerConnection =
215-
new CxxInspectorPackagerConnection(getInspectorDeviceUrl(), mPackageName);
216-
} else {
217-
// TODO(T190163403): Remove legacy InspectorPackagerConnection
218-
mInspectorPackagerConnection =
219-
new InspectorPackagerConnection(getInspectorDeviceUrl(), mPackageName);
220-
}
213+
mInspectorPackagerConnection =
214+
new CxxInspectorPackagerConnection(getInspectorDeviceUrl(), mPackageName);
221215
mInspectorPackagerConnection.connect();
222216
return null;
223217
}

0 commit comments

Comments
 (0)