func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
print(UIApplicationBackgroundFetchIntervalMinimum)
UIApplication.shared.setMinimumBackgroundFetchInterval(UIApplicationBackgroundFetchIntervalMinimum)
return true
}
func application(_ application: UIApplication, performFetchWithCompletionHandler completionHandler: @escaping (UIBackgroundFetchResult) -> Void) {
completionHandler(.newData)
}
이것은 내 코드이며 Xcode에서 디버그> 배경 시뮬레이션은 이유없이 내 앱 크래시를 가져옵니다. 기능> 배경 모드> 배경 가져 오기 ... 아이디어가 활성화 되었습니까?Swift3 - 디버그시 백그라운드 페치 크래시
시뮬레이터의 iPhone에서만 작동이 중단됩니다. 문제가 없습니다.
를 해결할의 Info.plist 파일
이를 추가하려고? –
내 대답을 확인하십시오 –
https://blog.newrelic.com/2016/01/13/ios9-background-execution/ –