title: How to respond to local notification when app is closed in iOS10?
body: <p>How to respond to local notification when app is completly closed (not in background)? </p>
  
  <p>When the app is running in the background or foreground everything works fine. But when the app is closed and I'm trying to answer to a notification, only <code>"application didFinishLaunchingWithOptions"</code> gets called, <code>"userNotificationCenter didRecive response</code>" isn't answering.</p>
  
  <p>I found this question (<a href="https://stackoverflow.com/questions/39655180/how-to-handle-unnotificationaction-when-app-is-closed">How to handle UNNotificationAction when app is closed?</a>) but in my case it doesn't work neither at a real device nor in a simulator.</p>
  
  <p>I also noticed that the function <code>"UNUserNotificationCenter.current().getDeliveredNotifications()"</code> returns <code>nil</code> when I'm responding to a notification while app is closed.</p>