From 12f2782fef89307a75aca388092c35c2f65b1411 Mon Sep 17 00:00:00 2001 From: Szymon Stasik Date: Mon, 10 Jun 2019 12:55:26 -0500 Subject: [PATCH] feat(diagnostic): add requestRemoteNotificationsAuthorization method (#3051) solves #3050 while diagnostic plugin docs may be confusing, the `requestRemoteNotificationsAuthorization(successCallback, errorCallback, types, omitRegistration)` signature is available in the sources: https://github.com/dpa99c/cordova-diagnostic-plugin/blob/0fac4a59d1f246c872c05f513b09f0e9c93abb51/www/ios/diagnostic.notifications.js#L162 --- src/@ionic-native/plugins/diagnostic/index.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/@ionic-native/plugins/diagnostic/index.ts b/src/@ionic-native/plugins/diagnostic/index.ts index 4aaceec71..99d708625 100644 --- a/src/@ionic-native/plugins/diagnostic/index.ts +++ b/src/@ionic-native/plugins/diagnostic/index.ts @@ -812,6 +812,15 @@ export class Diagnostic extends IonicNativePlugin { return; } + /** + * Requests reminders authorization for the application. + * @returns {Promise} + */ + @Cordova({ platforms: ['iOS'] }) + requestRemoteNotificationsAuthorization(types?: string[], omitRegistration?: boolean): Promise { + return; + } + /** * Indicates the current setting of notification types for the app in the Settings app. * Note: on iOS 8+, if "Allow Notifications" switch is OFF, all types will be returned as disabled.