fullstackreact / react-native-firestack

A firestack v3 react-native implementation
MIT License
715 stars 132 forks source link

Fix crash that happens when Firebase API key gets revoked #340

Closed KrauseFx closed 6 years ago

KrauseFx commented 7 years ago

Fixes https://github.com/fullstackreact/react-native-firestack/issues/318

This has been really hard to reproduce and track down: When an API key gets revoked the stored auth token is not valid any more, causing this error. error localizedFailureReason doesn't contain anything in that case, so it's nil, causing Objective-C to crash as you can't have it as a value for a dictionary.

It's probably save to have the default text here, but feel free to tweak it and modify the PR directly as necessary.

Let me know if you have any other questions. I'm using firestack for my side project wwdc.family :+1:

Salakar commented 7 years ago

@KrauseFx this has long since been fixed on my v3 fork, I re-wrote auth from scratch and it has better error handling and matching web SDK error codes.

I'd suggest moving over there for three reasons really:

Fork: https://github.com/Salakar/react-native-firestack

KrauseFx commented 7 years ago

@Salakar glad to hear. When do you think that will be part of master?