I have a problem and I don't know what else to do to solve it.
My app uses Google login from Firebase and works flawlessly in android studio. But when I uploaded it to the play store I stopped logging in.
Of course I already check that the firebase signatures are the same as in the google play console.
Attached the Login code of my app:
//button:
val googleConf = GoogleSignInOptions.Builder(GoogleSignInOptions.DEFAULT_SIGN_IN)
.requestIdToken(getString(R.string.default_web_client_id))
.requestEmail()
.build()
val googleClient = GoogleSignIn.getClient(this, googleConf)
googleClient.signOut()
startActivityForResult(googleClient.signInIntent, requestCodeGoogle)
//onactivityresult:
if (requestCode == requestCodeGoogle) {
val task = GoogleSignIn.getSignedInAccountFromIntent(data)
try {
val account = task.getResult(ApiException::class.java)
if (account != null) {
val credential = GoogleAuthProvider.getCredential(account.idToken, null)
mAuth.signInWithCredential(credential).addOnCompleteListener {
if (it.isSuccessful) {
val intent = Intent(this, MainActivity::class.java)
intent.flags = Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TASK
startActivity(intent)
} else {
}
}
}
} catch (e: ApiException) {
}
I really appreciate your help.
question from:
https://stackoverflow.com/questions/65873405/app-uploaded-to-play-store-does-not-start-session 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…