@@ -29,7 +29,8 @@ public protocol AuthProviderUI {
2929
3030public protocol PhoneAuthProviderSwift : AuthProviderSwift {
3131 @MainActor func verifyPhoneNumber( phoneNumber: String ) async throws -> String
32- @MainActor func createAuthCredential( verificationId: String , verificationCode: String ) async throws -> AuthCredential
32+ @MainActor func createAuthCredential( verificationId: String ,
33+ verificationCode: String ) async throws -> AuthCredential
3334}
3435
3536public enum AuthenticationState {
@@ -109,7 +110,10 @@ public final class AuthService {
109110 public init ( configuration: AuthConfiguration = AuthConfiguration ( ) , auth: Auth = Auth . auth ( ) ) {
110111 self . auth = auth
111112 self . configuration = configuration
112- string = StringUtils ( bundle: configuration. customStringsBundle ?? Bundle . module, languageCode: configuration. languageCode)
113+ string = StringUtils (
114+ bundle: configuration. customStringsBundle ?? Bundle . module,
115+ languageCode: configuration. languageCode
116+ )
113117 listenerManager = AuthListenerManager ( auth: auth, authEnvironment: self )
114118 FirebaseApp . registerLibrary ( " firebase-ui-ios " , withVersion: FirebaseAuthSwiftUIVersion . version)
115119 }
@@ -428,18 +432,18 @@ public extension AuthService {
428432 . invalidEmailLink ( " email address is missing from app storage. Is this the same device? " )
429433 }
430434 let urlString = url. absoluteString
431-
432- // Extract the actual auth link from Firebase Dynamic Link
433- guard let dynamicLink = CommonUtils . getQueryParamValue ( from : urlString , paramName : " link " ) else {
435+
436+ guard let originalLink = CommonUtils . getQueryParamValue ( from: urlString , paramName : " link " )
437+ else {
434438 throw AuthServiceError
435- . invalidEmailLink ( " Dynamic Link 'link' parameter is missing from the email link URL" )
439+ . invalidEmailLink ( " 'link' parameter is missing from the email link URL " )
436440 }
437-
438- guard let link = dynamicLink . removingPercentEncoding else {
441+
442+ guard let link = originalLink . removingPercentEncoding else {
439443 throw AuthServiceError
440444 . invalidEmailLink ( " Failed to decode Link URL " )
441445 }
442-
446+
443447 guard let continueUrl = CommonUtils . getQueryParamValue ( from: link, paramName: " continueUrl " )
444448 else {
445449 throw AuthServiceError
0 commit comments