diff --git a/blockchain/src/main/java/com/tangem/blockchain/blockchains/ethereum/EthereumWalletManager.kt b/blockchain/src/main/java/com/tangem/blockchain/blockchains/ethereum/EthereumWalletManager.kt index c72c98800..422baec44 100644 --- a/blockchain/src/main/java/com/tangem/blockchain/blockchains/ethereum/EthereumWalletManager.kt +++ b/blockchain/src/main/java/com/tangem/blockchain/blockchains/ethereum/EthereumWalletManager.kt @@ -92,11 +92,15 @@ open class EthereumWalletManager( return when (val signResponse = sign(transactionData, signer)) { is Result.Success -> { - val transactionToSend = transactionBuilder.buildForSend( - transaction = transactionData, - signature = signResponse.data.first, - compiledTransaction = signResponse.data.second, - ) + val transactionToSend = try { + transactionBuilder.buildForSend( + transaction = transactionData, + signature = signResponse.data.first, + compiledTransaction = signResponse.data.second, + ) + } catch (e: BlockchainSdkError.FailedToBuildTx) { + return Result.Failure(e) + } when (val sendResult = networkProvider.sendTransaction(transactionToSend.toHexString())) { is SimpleResult.Success -> { diff --git a/blockchain/src/main/java/com/tangem/blockchain/common/network/interceptors/HttpLoggingInterceptor.kt b/blockchain/src/main/java/com/tangem/blockchain/common/network/interceptors/HttpLoggingInterceptor.kt index 0077e8b9c..da3329de8 100644 --- a/blockchain/src/main/java/com/tangem/blockchain/common/network/interceptors/HttpLoggingInterceptor.kt +++ b/blockchain/src/main/java/com/tangem/blockchain/common/network/interceptors/HttpLoggingInterceptor.kt @@ -1,6 +1,5 @@ package com.tangem.blockchain.common.network.interceptors -import android.util.Log import com.squareup.moshi.adapter import com.tangem.blockchain.common.BlockchainSdkConfig import com.tangem.blockchain.common.di.DepsContainer @@ -123,7 +122,6 @@ internal object HttpLoggingInterceptor : Interceptor { val responseBody = response.body!! val contentLength = responseBody.contentLength() - Log.e("logg--", "contentLength: $contentLength") val message = if (!response.promisesBody()) { "<-- END HTTP" } else if (bodyHasUnknownEncoding(response.headers)) { @@ -152,7 +150,6 @@ internal object HttpLoggingInterceptor : Interceptor { if (!buffer.isProbablyUtf8()) { "<-- END HTTP (binary ${buffer.size}-byte body omitted)" } else { - Log.e("logg--", "${buffer.size}") val json = if (contentLength != 0L) { buffer.clone().readString(charset).beautifyJson() } else {