pass noop for android platform

This commit is contained in:
Ryan Grey 2018-07-23 16:52:24 +01:00
parent b6885b0125
commit fac0767d5d
1 changed files with 9 additions and 1 deletions

View File

@ -90,7 +90,15 @@ export default class Notifications extends ModuleBase {
'notifications_notification_displayed',
(notification: NativeNotification) => {
const rnNotification = new Notification(notification);
const done = (fetchResult: string) => getNativeModule(this).complete(rnNotification.notificationId, fetchResult);
const done = Platform.select({
ios: (fetchResult: string) =>
getNativeModule(this).complete(
rnNotification.notificationId,
fetchResult
),
android: () => {},
});
SharedEventEmitter.emit(
'onNotificationDisplayed',
rnNotification,