Updated on 2026-08-14

This commit is contained in:
Tangem 2026-04-14 15:13:37 +04:00
parent e0d6b165c0
commit 2b1baa61fe

View file

@ -32,9 +32,11 @@ class AssociateAssetUseCase(
val networkCoin = multiWalletCryptoCurrenciesSupplier.getSyncOrNull(
params = MultiWalletCryptoCurrenciesProducer.Params(userWallet.walletId),
)
?.firstOrNull {
?.firstOrNull { cryptoCurrency ->
val network = currency.network
it.network.id == network.id && it.network.derivationPath == network.derivationPath
cryptoCurrency is CryptoCurrency.Coin &&
cryptoCurrency.network.id == network.id &&
cryptoCurrency.network.derivationPath == network.derivationPath
}
?: error("Unable to create network coin for currencyID: ${currency.id}")