From 98295c71c174bd65642ad73e0ad29927fd80df25 Mon Sep 17 00:00:00 2001 From: milan_ Date: Tue, 10 Jul 2018 15:47:59 +0200 Subject: [PATCH] fix duplicate interface definition of class 'RCTBridge' and 'RCTBridgeModule', RN +0.40.0 --- RCTWeChat/RCTWeChat/RCTWeChat.h | 6 +++++- RCTWeChat/RCTWeChat/RCTWeChat.m | 4 ++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/RCTWeChat/RCTWeChat/RCTWeChat.h b/RCTWeChat/RCTWeChat/RCTWeChat.h index 9850e3e..a229f88 100644 --- a/RCTWeChat/RCTWeChat/RCTWeChat.h +++ b/RCTWeChat/RCTWeChat/RCTWeChat.h @@ -7,7 +7,11 @@ // #import +#if __has_include() +#import +#else #import "RCTBridgeModule.h" +#endif #import "WXApi.h" @interface RCTWeChat : NSObject @@ -16,4 +20,4 @@ - (BOOL) handleOpenURL:(NSURL *)url; -@end \ No newline at end of file +@end diff --git a/RCTWeChat/RCTWeChat/RCTWeChat.m b/RCTWeChat/RCTWeChat/RCTWeChat.m index 7a42ed7..2fc63aa 100644 --- a/RCTWeChat/RCTWeChat/RCTWeChat.m +++ b/RCTWeChat/RCTWeChat/RCTWeChat.m @@ -7,7 +7,11 @@ // #import "RCTWeChat.h" +#if __has_include() +#import +#else #import "RCTBridge.h" +#endif #import "RCTEventDispatcher.h" #import "WXApi.h" #import "WXApiObject.h"