Updated on 2026-08-14
This commit is contained in:
parent
feb4cf76c9
commit
173b076e5a
1 changed files with 7 additions and 10 deletions
|
|
@ -67,16 +67,13 @@ internal class AddCustomTokenHub : BaseStoreHub<AddCustomTokenState>("AddCustomT
|
|||
if (!action.blockchainNetwork.isUserInput) return
|
||||
|
||||
val contractAddress = ContractAddress.getFieldValue<String>()
|
||||
when (validateContractAddressAndNotify(contractAddress)) {
|
||||
is AddCustomTokenError.InvalidContractAddress -> {
|
||||
val isAlreadyAdded = isBlockchainPersistIntoAppSavedTokensList(
|
||||
selectedNetwork = action.blockchainNetwork.value
|
||||
)
|
||||
updateWarningAlreadyAdded(isAlreadyAdded)
|
||||
checkAndUpdateAddButton()
|
||||
}
|
||||
else -> {}
|
||||
}
|
||||
validateContractAddressAndNotify(contractAddress)
|
||||
|
||||
val isAlreadyAdded = isBlockchainPersistIntoAppSavedTokensList(
|
||||
selectedNetwork = action.blockchainNetwork.value
|
||||
)
|
||||
updateWarningAlreadyAdded(isAlreadyAdded)
|
||||
checkAndUpdateAddButton()
|
||||
}
|
||||
is OnTokenDerivationPathChanged -> {
|
||||
val isAlreadyAdded = if (ContractAddress.isFilled()) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue