Generic Fixes (#1373)
* Fix exchanges not showing * Fix button text on Monero receive screen * Temp fix for ERC20 and SPL tokens not having raw value * Manually Add Trocador new providers temporarily until API integration * properly handle nullability of n2 node [skip ci] --------- Co-authored-by: tuxsudo <tuxsudo@tux.pizza>
Omar Hatem committed
Apr 12, 2024 at 16:01 UTC
1769db1641c37aa6d829bb0270c6d72ed78b3fb8
6 files changed
+21
-12
cw_core/lib/n2_node.dart
+1
-1
@@ -14,7 +14,7 @@ class N2Node {
14
String? alias;
15
16
factory N2Node.fromJson(Map<String, dynamic> json) => N2Node(
17
- weight: double.tryParse((json['weight'] as num).toString()),
17
+ weight: double.tryParse((json['weight'] as num?).toString()),
18
uptime: json['uptime'] as String?,
19
score: json['score'] as int?,
20
account: json['rep_address'] as String?,
cw_core/lib/wallet_addresses.dart
+2
-1
@@ -41,5 +41,6 @@ abstract class WalletAddresses {
41
}
42
}
43
44
- bool containsAddress(String address) => allAddressesMap.containsKey(address);
44
+ bool containsAddress(String address) =>
45
+ addressesMap.containsKey(address) || allAddressesMap.containsKey(address);
46
}
lib/exchange/provider/trocador_exchange_provider.dart
+11
-1
@@ -32,7 +32,17 @@ class TrocadorExchangeProvider extends ExchangeProvider {
32
'Exolix',
33
'Godex',
34
'Exch',
35
- 'CoinCraddle'
35
+ 'CoinCraddle',
36
+ 'Alfacash',
37
+ 'LocalMonero',
38
+ 'XChange',
39
+ 'NeroSwap',
40
+ 'Changee',
41
+ 'BitcoinVN',
42
+ 'EasyBit',
43
+ 'WizardSwap',
44
+ 'Quantex',
45
+ 'SwapSpace',
46
];
47
48
static const List<CryptoCurrency> _notSupported = [
lib/view_model/send/send_view_model.dart
+5
-3
@@ -156,10 +156,10 @@ abstract class SendViewModelBase extends WalletChangeListenerViewModel with Stor
156
return priority;
157
}
158
159
-
159
int? getCustomPriorityIndex(List<TransactionPriority> priorities) {
160
if (wallet.type == WalletType.bitcoin) {
162
- final customItem = priorities.firstWhereOrNull((element) => element == bitcoin!.getBitcoinTransactionPriorityCustom());
161
+ final customItem = priorities
162
+ .firstWhereOrNull((element) => element == bitcoin!.getBitcoinTransactionPriorityCustom());
163
164
return customItem != null ? priorities.indexOf(customItem) : null;
165
}
@@ -503,7 +503,9 @@ abstract class SendViewModelBase extends WalletChangeListenerViewModel with Stor
503
address = output.address;
504
}
505
506
- if (address.isNotEmpty && !contactAddresses.contains(address)) {
506
+ if (address.isNotEmpty &&
507
+ !contactAddresses.contains(address) &&
508
+ selectedCryptoCurrency.raw != -1) {
509
return ContactRecord(
510
contactListViewModel.contactSource,
511
Contact(
lib/view_model/wallet_address_list/wallet_address_list_view_model.dart
-4
@@ -213,10 +213,6 @@ abstract class WalletAddressListViewModelBase extends WalletChangeListenerViewMo
213
return S.current.addresses;
214
}
215
216
- if (isAutoGenerateSubaddressEnabled) {
217
- return hasAccounts ? S.current.accounts : S.current.account;
218
- }
219
-
216
return hasAccounts ? S.current.accounts_subaddresses : S.current.addresses;
217
}
218
scripts/ios/app_env.sh
+2
-2
@@ -18,8 +18,8 @@ MONERO_COM_BUILD_NUMBER=77
18
MONERO_COM_BUNDLE_ID="com.cakewallet.monero"
19
20
CAKEWALLET_NAME="Cake Wallet"
21
-CAKEWALLET_VERSION="4.15.3"
22
-CAKEWALLET_BUILD_NUMBER=221
21
+CAKEWALLET_VERSION="4.16.0"
22
+CAKEWALLET_BUILD_NUMBER=226
23
CAKEWALLET_BUNDLE_ID="com.fotolockr.cakewallet"
24
25
HAVEN_NAME="Haven"