Custom URL Schemes with signin with google facebook.

scheme = url.scheme
path = url.path
query = url.query
print("Full URL \(url.absoluteString)");
print("Scheme: \(url.scheme)");
print("Query String: \(url.query)");
if(url.query != nil) {
let queryKeyValue = url.query!.componentsSeparatedByString("&");
for keyValue in queryKeyValue {
let kv = keyValue.componentsSeparatedByString("=");
if(kv.count > 1) {
print("\(kv[0]): \(kv[1])");
}
}
}
if url.scheme.hasPrefix("fb") { return FBSDKApplicationDelegate.sharedInstance() .application(application, openURL: url, sourceApplication: sourceApplication, annotation: annotation)
} else if url.scheme.hasPrefix("com.google") { return GIDSignIn.sharedInstance().handleURL(url, sourceApplication: sourceApplication, annotation: annotation) }
return true