title: applicationWillEnterForeground is getting hit when user navigate from other app
body: <p>I am using the following logic to check if user's token is expired when user is coming from background to foreground which is great and work like a charm!</p>
  <p>However, there is scenario when user is already on the foreground and clicks on Login Button, it takes user to third party app (Microsoft Authenticator app) and validate user credentials and then it comes back to my app and hit this logic again which is not desired. I wonder how to skip the following logic if user coming from third party app.</p>
  <pre><code>func applicationWillEnterForeground(_ application: UIApplication) {
      // the transition from the background to the active state
     guard !isTokenExpired() else {
        navigateToLoginViewController()
        return
     }
  }
  </code></pre>