Generic fixes and enhancements (#1083)

* Add exception handler to fiat APIs
Increase send card size for coin control
Fix Monero.com unspent coins hive box issue
minor bug fix

* Remove EIP-1559 parameters from Eth transaction
Enhance error reporting

* Throw error if not enough monero utx outputs are selected

* Fix Search text color

* Fix Ethereum sending EIP-1559 transactions

* Add transaction data to ERC20 transactions

* Add input check in single output transactions as well

* Fix Node deletion issue
Handle user input error in anonpay

* Remove exception handler from fiat conversion since it's not working with isolates

* Require enough utxo for amount and fees; More insightful Error messages

* Add cakewallet to applinks [skip ci]

* Add cakewallet app link for iOS [skip ci]

* Add applink depending on app scheme variable

* Add applink in iOS custom to the app getting built [skip ci]

* Handle normal app links without considering them as Payment URIs

* Minor fix [skip ci]

* Fixate encrypt package version as the recent update they made has some issues [skip ci]

---------

Co-authored-by: Konstantin Ullrich <konstantinullrich12@gmail.com>
This commit is contained in:
Omar Hatem
2023-09-14 22:14:16 +03:00
committed by GitHub
co-authored by Konstantin Ullrich
parent 4c9c6a1eae
commit ce4d375abf
18 changed files with 94 additions and 16 deletions
@@ -93,7 +93,11 @@ abstract class AnonInvoicePageViewModelBase with Store {
Future<void> createInvoice() async {
state = IsExecutingState();
if (amount.isNotEmpty) {
final amountInCrypto = double.parse(amount);
final amountInCrypto = double.tryParse(amount);
if (amountInCrypto == null) {
state = FailureState('Amount is invalid');
return;
}
if (minimum != null && amountInCrypto < minimum!) {
state = FailureState('Amount is too small');
return;
@@ -225,7 +225,7 @@ abstract class ExchangeViewModelBase extends WalletChangeListenerViewModel with
@computed
List<WalletContact> get walletContactsToShow => contactListViewModel.walletContacts
.where((element) => receiveCurrency == null || element.type == receiveCurrency)
.where((element) => element.type == receiveCurrency)
.toList();
@action
@@ -550,6 +550,9 @@ abstract class ExchangeViewModelBase extends WalletChangeListenerViewModel with
amount = amount.replaceAll(',', '.');
if (limitsState is LimitsLoadedSuccessfully) {
if (double.tryParse(amount) == null) {
continue;
}
if (limits.max != null && double.parse(amount) < limits.min!) {
continue;
} else if (limits.max != null && double.parse(amount) > limits.max!) {