Skip to content

Commit 8a9019b

Browse files
fix: update error for provider sign-in
1 parent 9e3219c commit 8a9019b

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

FirebaseSwiftUI/FirebaseAuthSwiftUI/Sources/Services/AuthService.swift

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -132,9 +132,14 @@ public final class AuthService {
132132
}
133133

134134
public func signIn(_ provider: AuthProviderSwift) async throws -> SignInOutcome {
135-
let credential = try await provider.createAuthCredential()
136-
let result = try await signIn(credentials: credential)
137-
return result
135+
do {
136+
let credential = try await provider.createAuthCredential()
137+
let result = try await signIn(credentials: credential)
138+
return result
139+
} catch {
140+
updateError(message: string.localizedErrorMessage(for: error))
141+
throw error
142+
}
138143
}
139144

140145
// MARK: - End Provider APIs

0 commit comments

Comments
 (0)