From c9605cd66fcbb4f043bd9fab4bae82e5480b46fd Mon Sep 17 00:00:00 2001 From: Artal Druk Date: Thu, 2 May 2019 15:28:08 +0300 Subject: [PATCH] Revert "Fix unrecognized selector crash on UNNotification cast" This reverts commit 0c21b4bda1062396513d1ad2efe9116cfdf78729. --- RNNotifications/RNNotifications.m | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/RNNotifications/RNNotifications.m b/RNNotifications/RNNotifications.m index f74840d..cafa406 100644 --- a/RNNotifications/RNNotifications.m +++ b/RNNotifications/RNNotifications.m @@ -247,11 +247,9 @@ RCT_EXPORT_MODULE() NSMutableDictionary* info = [[NSMutableDictionary alloc] initWithDictionary:@{ @"identifier": identifier, @"completionKey": completionKey }]; // add text - if ([response isKindOfClass:[UNTextInputNotificationResponse class]]) { - NSString* text = ((UNTextInputNotificationResponse*)response).userText; - if (text != NULL) { - info[@"text"] = text; - } + NSString* text = ((UNTextInputNotificationResponse*)response).userText;//[response objectForKey:UIUserNotificationActionResponseTypedTextKey]; + if (text != NULL) { + info[@"text"] = text; } NSDictionary* userInfo = response.notification.request.content.userInfo; -- 2.26.2