File tree Expand file tree Collapse file tree 1 file changed +3
-0
lines changed
Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ @interface RCTInspectorPackagerConnection () <RCTSRWebSocketDelegate> {
1818 NSURL *_url;
1919 NSMutableDictionary <NSString *, RCTInspectorLocalConnection *> *_inspectorConnections;
2020 RCTSRWebSocket *_webSocket;
21+ dispatch_queue_t _jsQueue;
2122 BOOL _closed;
2223 BOOL _suppressConnectionErrors;
2324}
@@ -45,6 +46,7 @@ - (instancetype)initWithURL:(NSURL *)url
4546 if (self = [super init ]) {
4647 _url = url;
4748 _inspectorConnections = [NSMutableDictionary new ];
49+ _jsQueue = dispatch_queue_create (" com.facebook.react.WebSocketExecutor" , DISPATCH_QUEUE_SERIAL);
4850 }
4951 return self;
5052}
@@ -215,6 +217,7 @@ - (void)connect
215217 // timeouts, but it appears the iOS RCTSRWebSocket API doesn't have the same
216218 // implemented options.
217219 _webSocket = [[RCTSRWebSocket alloc ] initWithURL: _url];
220+ [_webSocket setDelegateDispatchQueue: _jsQueue];
218221 _webSocket.delegate = self;
219222 [_webSocket open ];
220223}
You can’t perform that action at this time.
0 commit comments