mirror of
https://github.com/bitwarden/android.git
synced 2026-05-25 23:46:58 -05:00
Deps: Update Coroutines to v1.11.0 (#6959)
This commit is contained in:
@@ -45,7 +45,6 @@ import com.x8bit.bitwarden.data.vault.datasource.sdk.model.RegisterFido2Credenti
|
||||
import com.x8bit.bitwarden.data.vault.datasource.sdk.util.toAndroidAttestationResponse
|
||||
import com.x8bit.bitwarden.data.vault.datasource.sdk.util.toAndroidFido2PublicKeyCredential
|
||||
import com.x8bit.bitwarden.data.vault.repository.VaultRepository
|
||||
import kotlinx.coroutines.CoroutineScope
|
||||
import kotlinx.coroutines.flow.fold
|
||||
import kotlinx.coroutines.withContext
|
||||
import kotlinx.serialization.json.Json
|
||||
@@ -65,12 +64,10 @@ class BitwardenCredentialManagerImpl(
|
||||
private val vaultRepository: VaultRepository,
|
||||
private val cipherMatchingManager: CipherMatchingManager,
|
||||
private val passkeyAttestationOptionsSanitizer: PasskeyAttestationOptionsSanitizer,
|
||||
dispatcherManager: DispatcherManager,
|
||||
private val dispatcherManager: DispatcherManager,
|
||||
) : BitwardenCredentialManager,
|
||||
Fido2CredentialStore by fido2CredentialStore {
|
||||
|
||||
private val ioScope = CoroutineScope(dispatcherManager.io)
|
||||
|
||||
override var isUserVerified: Boolean = false
|
||||
|
||||
override var authenticationAttempts: Int = 0
|
||||
@@ -179,7 +176,7 @@ class BitwardenCredentialManagerImpl(
|
||||
|
||||
override suspend fun getCredentialEntries(
|
||||
getCredentialsRequest: GetCredentialsRequest,
|
||||
): Result<List<CredentialEntry>> = withContext(ioScope.coroutineContext) {
|
||||
): Result<List<CredentialEntry>> = withContext(dispatcherManager.io) {
|
||||
val cipherListViews = vaultRepository
|
||||
.decryptCipherListResultStateFlow
|
||||
.takeUntilLoaded()
|
||||
|
||||
@@ -39,7 +39,7 @@ private const val RELEASE_BUILD = "release"
|
||||
class PrivilegedAppRepositoryImpl(
|
||||
private val privilegedAppDiskSource: PrivilegedAppDiskSource,
|
||||
private val assetManager: AssetManager,
|
||||
dispatcherManager: DispatcherManager,
|
||||
private val dispatcherManager: DispatcherManager,
|
||||
private val json: Json,
|
||||
) : PrivilegedAppRepository {
|
||||
|
||||
@@ -118,7 +118,7 @@ class PrivilegedAppRepositoryImpl(
|
||||
.toPrivilegedAppAllowListJson()
|
||||
|
||||
override suspend fun getGoogleTrustedPrivilegedAppsOrNull(): PrivilegedAppAllowListJson? =
|
||||
withContext(ioScope.coroutineContext) {
|
||||
withContext(dispatcherManager.io) {
|
||||
assetManager
|
||||
.readAsset(fileName = GOOGLE_ALLOW_LIST_FILE_NAME)
|
||||
.map { json.decodeFromStringOrNull<PrivilegedAppAllowListJson>(it) }
|
||||
@@ -126,7 +126,7 @@ class PrivilegedAppRepositoryImpl(
|
||||
}
|
||||
|
||||
override suspend fun getCommunityTrustedPrivilegedAppsOrNull(): PrivilegedAppAllowListJson? {
|
||||
return withContext(ioScope.coroutineContext) {
|
||||
return withContext(dispatcherManager.io) {
|
||||
assetManager
|
||||
.readAsset(fileName = COMMUNITY_ALLOW_LIST_FILE_NAME)
|
||||
.map { json.decodeFromStringOrNull<PrivilegedAppAllowListJson>(it) }
|
||||
|
||||
@@ -55,7 +55,7 @@ class GeneratorRepositoryImpl(
|
||||
private val vaultSdkSource: VaultSdkSource,
|
||||
private val passwordHistoryDiskSource: PasswordHistoryDiskSource,
|
||||
private val reviewPromptManager: ReviewPromptManager,
|
||||
dispatcherManager: DispatcherManager,
|
||||
private val dispatcherManager: DispatcherManager,
|
||||
) : GeneratorRepository {
|
||||
|
||||
private val scope = CoroutineScope(dispatcherManager.io)
|
||||
@@ -193,7 +193,7 @@ class GeneratorRepositoryImpl(
|
||||
|
||||
override suspend fun generateForwardedServiceUsername(
|
||||
forwardedServiceGeneratorRequest: UsernameGeneratorRequest.Forwarded,
|
||||
): GeneratedForwardedServiceUsernameResult = withContext(scope.coroutineContext) {
|
||||
): GeneratedForwardedServiceUsernameResult = withContext(dispatcherManager.io) {
|
||||
generatorSdkSource.generateForwardedServiceEmail(forwardedServiceGeneratorRequest)
|
||||
.fold(
|
||||
onSuccess = { generatedEmail ->
|
||||
|
||||
@@ -48,7 +48,7 @@ junit = "6.0.3"
|
||||
jvmTarget = "21"
|
||||
kotlin = "2.3.21"
|
||||
kotlinxCollectionsImmutable = "0.4.0"
|
||||
kotlinxCoroutines = "1.10.2"
|
||||
kotlinxCoroutines = "1.11.0"
|
||||
kotlinxSerialization = "1.11.0"
|
||||
kotlinxKover = "0.9.8"
|
||||
ksp = "2.3.7"
|
||||
|
||||
Reference in New Issue
Block a user