Skip to content

Commit

Permalink
"notRequests" is null not an object on xcode 11 ios 13 #167
Browse files Browse the repository at this point in the history
  • Loading branch information
EddyVerbruggen committed Dec 8, 2019
1 parent c0b81bf commit c7218f0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions src/local-notifications.ios.ts
Original file line number Diff line number Diff line change
Expand Up @@ -412,8 +412,10 @@ export class LocalNotificationsImpl extends LocalNotificationsCommon implements

if (LocalNotificationsImpl.isUNUserNotificationCenterAvailable()) {
UNUserNotificationCenter.currentNotificationCenter().getPendingNotificationRequestsWithCompletionHandler((notRequests: NSArray<UNNotificationRequest>) => {
for (let i = 0; i < notRequests.count; i++) {
scheduledIds.push(notRequests[i].identifier);
if (notRequests) {
for (let i = 0; i < notRequests.count; i++) {
scheduledIds.push(notRequests[i].identifier);
}
}
resolve(scheduledIds.map(Number));
});
Expand Down
2 changes: 1 addition & 1 deletion src/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "nativescript-local-notifications",
"version": "4.1.3",
"version": "4.1.4",
"description": "The Local Notifications plugin allows your app to show notifications when the app is not running. Just like remote push notifications, but a few orders of magnitude easier to set up.",
"main": "local-notifications",
"typings": "index.d.ts",
Expand Down

0 comments on commit c7218f0

Please sign in to comment.