Skip to content

Commit e7fb2c7

Browse files
committed
Remove kJavascriptResponse notification on default notification center. If we are going to publish notifications, then they should be published for all events and not just for responses. @vontio, feel free to create another PR with notifications for responses, events, etc
1 parent 9c2bdd0 commit e7fb2c7

File tree

2 files changed

+0
-2
lines changed

2 files changed

+0
-2
lines changed

WebViewJavascriptBridge/WebViewJavascriptBridgeBase.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
#define kCustomProtocolScheme @"wvjbscheme"
1111
#define kQueueHasMessage @"__WVJB_QUEUE_MESSAGE__"
1212
#define kBridgeLoaded @"__BRIDGE_LOADED__"
13-
#define kJavascriptResponse @"__JAVASCRIPT_RESPONSE__"
1413

1514
typedef void (^WVJBResponseCallback)(id responseData);
1615
typedef void (^WVJBHandler)(id data, WVJBResponseCallback responseCallback);

WebViewJavascriptBridge/WebViewJavascriptBridgeBase.m

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ - (void)flushMessageQueue:(NSString *)messageQueueString{
7676

7777
NSString* responseId = message[@"responseId"];
7878
if (responseId) {
79-
[[NSNotificationCenter defaultCenter] postNotificationName: kJavascriptResponse object: self userInfo:message];
8079
WVJBResponseCallback responseCallback = _responseCallbacks[responseId];
8180
responseCallback(message[@"responseData"]);
8281
[self.responseCallbacks removeObjectForKey:responseId];

0 commit comments

Comments
 (0)