Skip to content

Commit

Permalink
Added FRAG <com.ohbibi.fps> Unable to log in fix
Browse files Browse the repository at this point in the history
  • Loading branch information
DaVinci9196 committed Nov 11, 2024
1 parent 4d795e4 commit b22b13c
Showing 1 changed file with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
package org.microg.gms.auth.signin

import android.accounts.Account
import android.accounts.AccountManager
import android.content.Context
import android.os.Bundle
import android.os.Parcel
Expand All @@ -37,6 +38,7 @@ import com.google.android.gms.common.internal.ConnectionInfo
import com.google.android.gms.common.internal.GetServiceRequest
import com.google.android.gms.common.internal.IGmsCallbacks
import org.microg.gms.BaseService
import org.microg.gms.auth.AuthConstants
import org.microg.gms.auth.AuthPrefs
import org.microg.gms.common.GmsService
import org.microg.gms.common.PackageUtils
Expand Down Expand Up @@ -77,10 +79,14 @@ class AuthSignInServiceImpl(
}
lifecycleScope.launchWhenStarted {
try {
val account = account ?: options?.account ?: SignInConfigurationService.getDefaultAccount(context, packageName)
val account = account
?: options?.account
?: SignInConfigurationService.getDefaultAccount(context, packageName)
?: AccountManager.get(context).getAccountsByType(AuthConstants.DEFAULT_ACCOUNT_TYPE).firstOrNull()
Log.d(TAG, "silentSignIn: account -> ${account?.name}")
if (account != null && options?.isForceCodeForRefreshToken != true) {
if (getOAuthManager(context, packageName, options, account).isPermitted || AuthPrefs.isTrustGooglePermitted(context)) {
val googleSignInAccount = performSignIn(context, packageName, options, account)
val googleSignInAccount = performSignIn(context, packageName, options, account, true)
if (googleSignInAccount != null) {
sendResult(googleSignInAccount, Status(CommonStatusCodes.SUCCESS))
} else {
Expand Down

0 comments on commit b22b13c

Please sign in to comment.