didReceiveRemoteNotification:fetchCompletionHandler: but the completion handler was never called
ios, iphone, swift
Solution
Remove the println or change it to a NSLog, then try again. Most likely the problem is caused because this method is coming to you in the background and not on the main thread. println is much simpler than NSLog, which is thread-safe and been hardened for years and years.
Problem
I've been trying to implement the fetch completion block with no luck. Whenever I send an APN, xcode still complains that it's not implemented. Here's my code ``` func application(application: UIApplication, didReceiveRemoteNotification userInfo: [NSObject : AnyObject], fetchCompletionHandler completionHandler: (UIBackgroundFetchResult) -> Void) { println("2. User Data", userInfo) completionHandler(UIBackgroundFetchResult.NewData) } ``` and the warning I am getting in the xcode console is this ``` Warning: Application delegate received call to -application:didReceiveRemoteNotification:fetchCompletionHandler: but the completion handler was never called. ``` Not sure if I am implementing the right syntax here