소스 검색

Fix didReceiveLocalNotification: call within didFinishLaunchingWithOptions:

Sebastián Katzer 11 년 전
부모
커밋
87f29b67b0
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      src/ios/APPLocalNotification.m

+ 2 - 2
src/ios/APPLocalNotification.m

@@ -316,7 +316,7 @@ NSString *const kAPP_LOCALNOTIFICATION = @"APP_LOCALNOTIFICATION";
 
     if (localNotification)
     {
-        [self didReceiveLocalNotification:notification];
+        [self didReceiveLocalNotification:[NSNotification notificationWithName:CDVLocalNotification object:localNotification]];
     }
 }
 
@@ -355,7 +355,7 @@ NSString *const kAPP_LOCALNOTIFICATION = @"APP_LOCALNOTIFICATION";
  * @param {String} id    The ID of the notification
  * @param {String} json  A custom (JSON) string
  */
-- (void) fireEvent:(NSString*) event id:(NSString*) id json:(NSString*) json
+- (void) fireEvent:(NSString*)event id:(NSString*)id json:(NSString*)json
 {
     UIApplicationState state = [[UIApplication sharedApplication] applicationState];
     bool isActive            = state == UIApplicationStateActive;