CW-443 Use networkWallets on OnRamper (#1012)
* CW-443 Use networkWallets on OnRamper * CW-443 Normalize XMR
Konstantin Ullrich committed
Jul 26, 2023 at 18:48 UTC
da2f1c62f56de919658170af1f8fae58eba3ee47
1 file changed
+4
-1
lib/buy/onramper/onramper_buy_provider.dart
+4
-1
@@ -20,6 +20,8 @@ class OnRamperBuyProvider {
20
switch (_wallet.currency) {
21
case CryptoCurrency.ltc:
22
return "LTC_LITECOIN";
23
+ case CryptoCurrency.xmr:
24
+ return "XMR_MONERO";
25
default:
26
return _wallet.currency.title;
27
}
@@ -60,11 +62,12 @@ class OnRamperBuyProvider {
62
break;
63
}
64
65
+ final networkName = _wallet.currency.fullName?.toUpperCase().replaceAll(" ", "");
66
67
return Uri.https(_baseUrl, '', <String, dynamic>{
68
'apiKey': _apiKey,
69
'defaultCrypto': _normalizeCryptoCurrency,
67
- 'wallets': '${_wallet.currency.title}:${_wallet.walletAddresses.address}',
70
+ 'networkWallets': '${networkName}:${_wallet.walletAddresses.address}',
71
'supportSell': "false",
72
'supportSwap': "false",
73
'primaryColor': primaryColor,