nil
을 푸시 알림을 받고 알림을 눌러 앱을 연 후 didFinishLaunchWithOptions
에 수신 한 이유는 무엇입니까? 백그라운드 에서뿐만 아니라 앱이 중지되었는지 다시 확인했습니다. nil
은 항상 로그에 기록됩니다. 응용 프로그램이 포 그라운드 모드에있는 경우 응용 프로그램이없는 경우 다음이 application:didReceiveRemoteNotification:
푸시 알림을받은 후 launchOptions이 nil이되는 이유는 무엇입니까?
를 통해 푸시 알림을 수신하지만
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
[MA init];
NSLog(@"%@", launchOptions);
if (!launchOptions) {
return YES;
}
id userInfo = launchOptions[UIApplicationLaunchOptionsRemoteNotificationKey];
if (userInfo[@"aps"] && userInfo[@"id"]) {
MAResult* result = [[MA data] resultById:userInfo[@"id"]];
if (result) {
[((UINavigationController *)self.window.rootViewController) pushViewController:[[MATaskDetails alloc] initWithResults:result] animated:YES];
}
}
return YES;
}
페이로드 내부에는 무엇이 있습니까? – null