I use UIBackgroundFetchResult to catch push notifications as below code...i use content availability = 1 also to detect in background mode
- (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo
fetchCompletionHandler:(void (^)   (UIBackgroundFetchResult))completionHandler {
Push is coming and is executed on here while app is active or background mode always BUT when i opened push,i cannot detect whether app is opened from push or not because it always enters if state
 if ( (application.applicationState == UIApplicationStateInactive || application.applicationState == UIApplicationStateBackground)  && (NotiType == 1 || NotiType == 2))
    {
}
