Hello Im getting this error when finally Logging in to my app. I have been following this tutorial: https://www.freecodecamp.org/news/react-native-firebase-tutorial/.
This is the error I get:
I believe Im getting the error from my Login page. this is the related code, if you need more lmk please. Thank you for all help
const onLoginPress = () => {
firebase
.auth()
.signInWithEmailAndPassword(email, password)
.then((response) => {
const uid = response.user.uid
const usersRef = firebase.firestore().collection('users')
usersRef
.doc(uid)
.get()
.then(firestoreDocument => {
if (!firestoreDocument.exists) {
alert("User does not exist anymore.")
return;
}
const user = firestoreDocument.data()
navigation.navigate('Loans', {user})
})
.catch(error => {
alert(error)
});
})
.catch(error => {
alert(error)
})
}