Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@

import FirebaseAuth
import UIKit
import GoogleSignIn
import FacebookCore

class SceneDelegate: UIResponder, UIWindowSceneDelegate {
var window: UIWindow?
Expand Down Expand Up @@ -53,10 +55,24 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate {
func scene(_ scene: UIScene, openURLContexts URLContexts: Set<UIOpenURLContext>) {
for urlContext in URLContexts {
let url = urlContext.url
_ = Auth.auth().canHandle(url)
if Auth.auth().canHandle(url) {
continue;
}
// Handle Google signins
if GIDSignIn.sharedInstance.handle(url) {
continue;
}
// Handle Facebook signins
if ApplicationDelegate.shared.application(
UIApplication.shared,
open: url,
sourceApplication: urlContext.options.sourceApplication,
annotation: urlContext.options.annotation
) {
continue
}
// URL not auth, Google, or Facebook related; it should be handled separately.
}

// URL not auth related; it should be handled separately.
}

func scene(_ scene: UIScene, continue userActivity: NSUserActivity) {
Expand Down
Loading