Commit 0065f5af authored by Sebastián Katzer's avatar Sebastián Katzer
Browse files

Callback functions should be undefined by default.

parent 2a660177
Loading
Loading
Loading
Loading
+1 −1
Changes for src/ios/APPLocalNotification.m: 1 added line, 1 removed line.
Original line number Diff line number Diff line
@@ -158,7 +158,7 @@
    NSString* callbackType            = isActive ? @"foreground" : @"background";
    NSString* callbackFn              = [notification.userInfo objectForKey:callbackType];

    if (callbackFn.length > 0)
    if (callbackFn && callbackFn.length > 0)
    {
        NSString* callback = [NSString stringWithFormat:@"setTimeout('%@(%@)',0)", callbackFn, id];

+2 −2
Changes for www/local-notification.js: 2 added lines, 2 removed lines.
Original line number Diff line number Diff line
@@ -26,8 +26,8 @@ LocalNotification.prototype = {
            badge:      0,
            id:         0,
            repeat:     '',
            background: '',
            foreground: ''
            background: undefined,
            foreground: undefined
        };

        switch (device.platform) {