react-native-google-signin/google-signin

My app shows google login panel, I changed the email and client Id in the code then get this error.

Closed this issue · 1 comments

Error is :
{"nativeStackAndroid":[],"userInfo":null,"message":"A non-recoverable sign in failure occurred","code":"12500"}<!--

code was working fine before change client ID:

code is here:
` const googleSignIN = () => {
GoogleSignin.configure({
androidClientId: CLIENT_ID
});

    GoogleSignin.hasPlayServices().then((hasPlayService) => {
        if (hasPlayService) {
            GoogleSignin.signIn().then(async (userInfo) => {
                console.log("userInfo", JSON.stringify(userInfo.user))
                setLoading(true);
                const social_Login_Data = {
                    email: userInfo.user.email,
                    name: userInfo.user.name
                }
                console.log("social_Login_Data : ", social_Login_Data);
                try {
                    const res = await api.post(`/Auth/login-single-signin`, social_Login_Data);
                    console.log("response : ", res.data);
                    if (res.data.ack === 1) {
                        console.log('success');
                        navigation.navigate('DrawerNavigation')
                    } else {
                        setItem('social_Login_Data', JSON.stringify(social_Login_Data))
                        navigation.navigate('VerifyEmail',{msg:res.data.message})
                    }
                    setLoading(false);
                } catch (e) {
                    setLoading(false);
                    alert(e)
                }
            }).catch((e) => {
                setLoading(false);
                console.log("ERROR IS1: " + JSON.stringify(e));
            })
        }
    }).catch((e) => {
        console.log("ERROR IS2: " + JSON.stringify(e));
    })
}`

Please help if anyone got this type error

Hello and thanks for reporting,

code was working fine before change client ID

this means something outside of the library has changed that caused it to stop working. This is not an issue with this lib.

Thank you 🙂