Updated on 2026-08-14
This commit is contained in:
parent
3539e8272a
commit
a74ee9640c
2 changed files with 3 additions and 5 deletions
|
|
@ -259,7 +259,7 @@ class TradeCryptoMiddleware {
|
|||
|
||||
private fun openSwap(currency: CryptoCurrency) {
|
||||
val bundle = bundleOf(
|
||||
SwapFragment.CURRENCY_BUNDLE_KEY to Json.encodeToString(currency),
|
||||
SwapFragment.CURRENCY_BUNDLE_KEY to currency
|
||||
)
|
||||
|
||||
store.dispatchOnMain(NavigationAction.NavigateTo(screen = AppScreen.Swap, bundle = bundle))
|
||||
|
|
|
|||
|
|
@ -50,10 +50,8 @@ internal class SwapViewModel @Inject constructor(
|
|||
savedStateHandle: SavedStateHandle,
|
||||
) : ViewModel(), DefaultLifecycleObserver {
|
||||
|
||||
private val initialCryptoCurrency = Json.decodeFromString<CryptoCurrency>(
|
||||
savedStateHandle[SwapFragment.CURRENCY_BUNDLE_KEY]
|
||||
?: error("no expected parameter Currency found"),
|
||||
)
|
||||
private val initialCryptoCurrency: CryptoCurrency = savedStateHandle[SwapFragment.CURRENCY_BUNDLE_KEY]
|
||||
?: error("no expected parameter CryptoCurrency found`")
|
||||
|
||||
private var isBalanceHidden = true
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue