mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-17 05:41:29 +02:00
fix uri generation for certain wallet types (#3126)
This commit is contained in:
@@ -482,6 +482,8 @@ abstract class ExchangeTradeViewModelBase with Store {
|
||||
final uriWalletType =
|
||||
cryptoCurrencyOrTokenToWalletType(fromCurrency) ?? wallet.type;
|
||||
|
||||
printV(uriWalletType);
|
||||
|
||||
switch (uriWalletType) {
|
||||
case WalletType.bitcoin:
|
||||
return BitcoinURI(address: inputAddress, amount: amount);
|
||||
@@ -510,7 +512,19 @@ abstract class ExchangeTradeViewModelBase with Store {
|
||||
return MoneroURI(
|
||||
address: inputAddress,
|
||||
amount: amount);
|
||||
default:
|
||||
case WalletType.litecoin:
|
||||
return LitecoinURI(amount: amount, address: inputAddress);
|
||||
case WalletType.nano:
|
||||
return NanoURI(amount: amount, address: inputAddress);
|
||||
case WalletType.zano:
|
||||
return ZanoURI(amount: amount, address: inputAddress);
|
||||
case WalletType.decred:
|
||||
return DecredURI(amount: amount, address: inputAddress);
|
||||
case WalletType.zcash:
|
||||
return ZcashURI(amount: amount, address: inputAddress);
|
||||
case WalletType.banano:
|
||||
case WalletType.none:
|
||||
case WalletType.haven:
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user