From ce5966bf10671e85b586ca3fd123d42b200fabb0 Mon Sep 17 00:00:00 2001 From: Yasin Simsek Date: Thu, 24 Aug 2017 01:46:58 +0200 Subject: [PATCH] feat(local-notifications): add `un` method to unsubscribe from events (#1871) --- src/@ionic-native/plugins/local-notifications/index.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/@ionic-native/plugins/local-notifications/index.ts b/src/@ionic-native/plugins/local-notifications/index.ts index fbaeb9c99..3d3bcfeb4 100644 --- a/src/@ionic-native/plugins/local-notifications/index.ts +++ b/src/@ionic-native/plugins/local-notifications/index.ts @@ -324,5 +324,15 @@ export class LocalNotifications extends IonicNativePlugin { }) on(eventName: string, callback: any): void { } + /** + * Removes a callback of a specific event + * @param eventName The name of the event. Available events: schedule, trigger, click, update, clear, clearall, cancel, cancelall + * @param callback Call back function. All events return notification and state parameter. clear and clearall return state parameter only. + */ + @Cordova({ + sync: true + }) + un(eventName: string, callback: any): void { } + }