Updated on 2026-08-14
This commit is contained in:
parent
cc037ed347
commit
56b509927c
8 changed files with 35 additions and 10 deletions
|
|
@ -114,6 +114,7 @@ internal class DefaultRampManager(
|
|||
userWalletId: UserWalletId,
|
||||
cryptoCurrencyStatus: CryptoCurrencyStatus,
|
||||
): ScenarioUnavailabilityReason {
|
||||
val yieldSupplyStatus = cryptoCurrencyStatus.value.yieldSupplyStatus
|
||||
return when {
|
||||
cryptoCurrencyStatus.value.amount.isNullOrZero() -> {
|
||||
ScenarioUnavailabilityReason.EmptyBalance(ScenarioUnavailabilityReason.WithdrawalScenario.SEND)
|
||||
|
|
@ -127,6 +128,9 @@ internal class DefaultRampManager(
|
|||
networkName = cryptoCurrencyStatus.currency.network.name,
|
||||
)
|
||||
}
|
||||
yieldSupplyStatus?.isAllowedToSpend == false && yieldSupplyStatus.isActive -> {
|
||||
ScenarioUnavailabilityReason.YieldSupplyApprovalRequired
|
||||
}
|
||||
else -> ScenarioUnavailabilityReason.None
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue