Updated on 2026-08-14
This commit is contained in:
parent
133c89dd7e
commit
dffa8b2658
12 changed files with 109 additions and 1 deletions
|
|
@ -1,5 +1,7 @@
|
|||
package com.tangem.data.hotwallet
|
||||
|
||||
import android.os.Build
|
||||
import androidx.annotation.ChecksSdkIntAtLeast
|
||||
import com.tangem.datasource.local.preferences.AppPreferencesStore
|
||||
import com.tangem.datasource.local.preferences.PreferencesKeys
|
||||
import com.tangem.datasource.local.preferences.utils.getObjectMap
|
||||
|
|
@ -12,6 +14,13 @@ internal class DefaultHotWalletRepository(
|
|||
private val appPreferencesStore: AppPreferencesStore,
|
||||
) : HotWalletRepository {
|
||||
|
||||
@ChecksSdkIntAtLeast(api = Build.VERSION_CODES.Q)
|
||||
override fun isWalletCreationSupported(): Boolean {
|
||||
return BuildConfig.DEBUG || Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q
|
||||
}
|
||||
|
||||
override fun getLeastSupportedAndroidVersionName(): String = "Android 10"
|
||||
|
||||
override fun accessCodeSkipped(userWalletId: UserWalletId): Flow<Boolean> = appPreferencesStore
|
||||
.getObjectMap<Boolean>(PreferencesKeys.ACCESS_CODE_SKIPPED_STATES_KEY)
|
||||
.map { it[userWalletId.stringValue] == true }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue