TODO: How to register a scheme for your app.
@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
public func application(_ application: UIApplication, open url: URL, sourceApplication: String?, annotation: Any) -> Bool {
// sb: this should never happen, as we only have one scheme registered,
// but just in case.
if url.scheme != "YOUR REGISTERED SCHEME" {
return false
}
// sb: segue to reset password
if url.path == "/reset-password" {
self.window!.rootViewController!.performSegue(withIdentifier: "segueToResetPassword", sender: self)
return true
}
return false
}
}