From a81120e6463ffbb71ec41a7753156a69494c5213 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stanis=C5=82aw=20Chmiela?= Date: Thu, 20 Aug 2020 19:06:13 +0200 Subject: [PATCH] Make RCTCxxBridge not care about the actual protocol implemented, only the method used --- React/CxxBridge/RCTCxxBridge.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/React/CxxBridge/RCTCxxBridge.mm b/React/CxxBridge/RCTCxxBridge.mm index a9bea58741a7a0..e0ab9f68446fdd 100644 --- a/React/CxxBridge/RCTCxxBridge.mm +++ b/React/CxxBridge/RCTCxxBridge.mm @@ -334,7 +334,7 @@ - (void)start // Prepare executor factory (shared_ptr for copy into block) std::shared_ptr executorFactory; if (!self.executorClass) { - if ([self.delegate conformsToProtocol:@protocol(RCTCxxBridgeDelegate)]) { + if ([self.delegate respondsToSelector:@selector(jsExecutorFactoryForBridge:)]) { id cxxDelegate = (id)self.delegate; executorFactory = std::make_shared(*reinterpret_cast([cxxDelegate jsExecutorFactoryForBridge:self])); }