Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FirAuthError exceptions on IOS returning whe whole NSError information #492

Open
pnametala opened this issue Apr 10, 2024 · 2 comments
Open

Comments

@pnametala
Copy link

Handling exceptions from Firebase Auth on both android and IOS using this lib works mostly as expected.

On the android side, the exceptions are handled as expected and you can use

try {
// your code here
} catch (e: Exception) {
//e.localizedMessage
}

on IOS, based on the code you create an Exception and pass NSError.toString() instead of NSLocalizedDescription.

Image for reference
image

Wondering if there's a way of doing the same on the IOS side and having access to the NSError properties itself.

@nbransby
Copy link
Member

Ideally they should be translated to the corresponding kmp/android exception like we do for js

@mr-kew
Copy link

mr-kew commented May 14, 2024

It is also related to this issue where on iOS the exceptions always have only the most general type FirebaseAuthException and not its corresponding subclass like on android.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants