In my Swift code to handle push notification I have this line:
if ( application.applicationState == UIApplicationStateInactive || application.applicationState == UIApplicationStateBackground) {
}
Which cause the compilation error: Use of unresolved identifier 'UIApplicationStateInactive'
Am I missing some import files?
Thanks
Currently your are using the identifiers for Objective-C. You need to use the identifier for swift:
Apple documentation for:
You can check the documentation for both languages in the Apple Documentation and choose the language in the top right corner.