 
         // start authentication session
         loadingView.errorView.isHidden = true
-        loadingView.activityIndicatorView.stp_startAnimatingAndShow()
         startAuthenticationSession(manifest: manifest)
     }
     

         On iOS13+, it is possible to swipe down on presented view controller to dismiss.
         In this case, we need to notify the delegate.
         */
        if #available(iOS 13.0, *) {
            notifyDelegate()
        }
    }
}


extension FinancialConnectionsWebFlowViewController {

    private func notifyDelegate(result: FinancialConnectionsSheet.Result) {
        delegate?.financialConnectionsWebFlow(viewController: self, didFinish: result)
        delegate = nil // prevent the delegate from being called again
    }

    private func startAuthenticationSession(manifest: FinancialConnectionsSessionManifest) {
        loadingView.activityIndicatorView.stp_startAnimatingAndShow()
        authSessionManager = AuthenticationSessionManager(manifest: manifest, window: view.window)
        authSessionManager?
            .start()
            .observe(using: { [weak self] (result) in
                guard let self = self else { return }
                self.loadingView.activityIndicatorView.stp_stopAnimatingAndHide()
                switch result {
                   case .success(.success):
                        self.fetchSession()
                   case .success(.webCancelled):
                       self.notifyDelegate(result: .canceled)
                   case .success(.nativeCancelled):
                       self.notifyDelegate(result: .canceled)
                   case .failure(let error):
                       self.notifyDelegate(result: .failed(error: error))
                   }
        })
    }

    private func fetchSession() {
        loadingView.activityIndicatorView.stp_startAnimatingAndShow()
        loadingView.errorView.isHidden = true
        sessionFetcher
            .fetchSession()
            .observe { [weak self] (result) in
