mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-20 06:08:34 +02:00
CW 781 replace all print statements with printV (#1733)
* replace all print statements with printV * restore backup error message * missing print statements, error fixes * Update cw_core/lib/utils/print_verbose.dart [skip ci] * Update cw_core/lib/utils/print_verbose.dart [skip ci] * CW-846: Correctly display balance (#1848) * Correctly display balance even with frozen coins * remove package= from AndroidMainfest.xml * update namespace * print -> printV --------- Co-authored-by: Omar Hatem <omarh.ismail1@gmail.com>
This commit is contained in:
@@ -404,8 +404,8 @@ class CWBitcoin extends Bitcoin {
|
||||
|
||||
list.add(dInfoCopy);
|
||||
} catch (e, s) {
|
||||
print("derivationInfoError: $e");
|
||||
print("derivationInfoStack: $s");
|
||||
printV("derivationInfoError: $e");
|
||||
printV("derivationInfoStack: $s");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -498,7 +498,7 @@ class CWBitcoin extends Bitcoin {
|
||||
try {
|
||||
return hardwareWalletService.getAvailableAccounts(index: index, limit: limit);
|
||||
} catch (err) {
|
||||
print(err);
|
||||
printV(err);
|
||||
throw err;
|
||||
}
|
||||
}
|
||||
@@ -510,7 +510,7 @@ class CWBitcoin extends Bitcoin {
|
||||
try {
|
||||
return hardwareWalletService.getAvailableAccounts(index: index, limit: limit);
|
||||
} catch (err) {
|
||||
print(err);
|
||||
printV(err);
|
||||
throw err;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ import 'package:cake_wallet/src/widgets/alert_with_one_action.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:cake_wallet/view_model/hardware_wallet/ledger_view_model.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -136,7 +137,7 @@ class DFXBuyProvider extends BuyProvider {
|
||||
return {};
|
||||
}
|
||||
} catch (e) {
|
||||
print('DFX Error fetching fiat currencies: $e');
|
||||
printV('DFX Error fetching fiat currencies: $e');
|
||||
return {};
|
||||
}
|
||||
}
|
||||
@@ -266,19 +267,19 @@ class DFXBuyProvider extends BuyProvider {
|
||||
quote.setCryptoCurrency = cryptoCurrency;
|
||||
return [quote];
|
||||
} else {
|
||||
print('DFX: Unexpected data type: ${responseData.runtimeType}');
|
||||
printV('DFX: Unexpected data type: ${responseData.runtimeType}');
|
||||
return null;
|
||||
}
|
||||
} else {
|
||||
if (responseData is Map<String, dynamic> && responseData.containsKey('message')) {
|
||||
print('DFX Error: ${responseData['message']}');
|
||||
printV('DFX Error: ${responseData['message']}');
|
||||
} else {
|
||||
print('DFX Failed to fetch buy quote: ${response.statusCode}');
|
||||
printV('DFX Failed to fetch buy quote: ${response.statusCode}');
|
||||
}
|
||||
return null;
|
||||
}
|
||||
} catch (e) {
|
||||
print('DFX Error fetching buy quote: $e');
|
||||
printV('DFX Error fetching buy quote: $e');
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@ import 'package:cake_wallet/generated/i18n.dart';
|
||||
import 'package:cake_wallet/src/widgets/alert_with_one_action.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'dart:developer';
|
||||
@@ -75,11 +76,11 @@ class MeldBuyProvider extends BuyProvider {
|
||||
data.map((e) => PaymentMethod.fromMeldJson(e as Map<String, dynamic>)).toList();
|
||||
return paymentMethods;
|
||||
} else {
|
||||
print('Meld: Failed to fetch payment types');
|
||||
printV('Meld: Failed to fetch payment types');
|
||||
return List<PaymentMethod>.empty();
|
||||
}
|
||||
} catch (e) {
|
||||
print('Meld: Failed to fetch payment types: $e');
|
||||
printV('Meld: Failed to fetch payment types: $e');
|
||||
return List<PaymentMethod>.empty();
|
||||
}
|
||||
}
|
||||
@@ -132,7 +133,7 @@ class MeldBuyProvider extends BuyProvider {
|
||||
return null;
|
||||
}
|
||||
} catch (e) {
|
||||
print('Error fetching buy quote: $e');
|
||||
printV('Error fetching buy quote: $e');
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,6 +18,7 @@ import 'package:cake_wallet/themes/theme_base.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:http/http.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
@@ -113,11 +114,11 @@ class MoonPayProvider extends BuyProvider {
|
||||
if (response.statusCode == 200) {
|
||||
return jsonDecode(response.body) as Map<String, dynamic>;
|
||||
} else {
|
||||
print('MoonPay does not support fiat: $fiatCurrency');
|
||||
printV('MoonPay does not support fiat: $fiatCurrency');
|
||||
return {};
|
||||
}
|
||||
} catch (e) {
|
||||
print('MoonPay Error fetching fiat currencies: $e');
|
||||
printV('MoonPay Error fetching fiat currencies: $e');
|
||||
return {};
|
||||
}
|
||||
}
|
||||
@@ -204,11 +205,11 @@ class MoonPayProvider extends BuyProvider {
|
||||
|
||||
return [quote];
|
||||
} else {
|
||||
print('Moon Pay: Error fetching buy quote: ');
|
||||
printV('Moon Pay: Error fetching buy quote: ');
|
||||
return null;
|
||||
}
|
||||
} catch (e) {
|
||||
print('Moon Pay: Error fetching buy quote: $e');
|
||||
printV('Moon Pay: Error fetching buy quote: $e');
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/themes/extensions/cake_text_theme.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:http/http.dart' as http;
|
||||
@@ -67,11 +68,11 @@ class OnRamperBuyProvider extends BuyProvider {
|
||||
.map((item) => PaymentMethod.fromOnramperJson(item as Map<String, dynamic>))
|
||||
.toList();
|
||||
} else {
|
||||
print('Failed to fetch available payment types');
|
||||
printV('Failed to fetch available payment types');
|
||||
return [];
|
||||
}
|
||||
} catch (e) {
|
||||
print('Failed to fetch available payment types: $e');
|
||||
printV('Failed to fetch available payment types: $e');
|
||||
return [];
|
||||
}
|
||||
}
|
||||
@@ -98,11 +99,11 @@ class OnRamperBuyProvider extends BuyProvider {
|
||||
|
||||
return result;
|
||||
} else {
|
||||
print('Failed to fetch onramp metadata');
|
||||
printV('Failed to fetch onramp metadata');
|
||||
return {};
|
||||
}
|
||||
} catch (e) {
|
||||
print('Error occurred: $e');
|
||||
printV('Error occurred: $e');
|
||||
return {};
|
||||
}
|
||||
}
|
||||
@@ -178,11 +179,11 @@ class OnRamperBuyProvider extends BuyProvider {
|
||||
|
||||
return validQuotes;
|
||||
} else {
|
||||
print('Onramper: Failed to fetch rate');
|
||||
printV('Onramper: Failed to fetch rate');
|
||||
return null;
|
||||
}
|
||||
} catch (e) {
|
||||
print('Onramper: Failed to fetch rate $e');
|
||||
printV('Onramper: Failed to fetch rate $e');
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,6 +13,7 @@ import 'package:cake_wallet/src/widgets/alert_with_one_action.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:cake_wallet/view_model/hardware_wallet/ledger_view_model.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -176,7 +177,7 @@ class RobinhoodBuyProvider extends BuyProvider {
|
||||
if (responseData.containsKey('message')) {
|
||||
log('Robinhood Error: ${responseData['message']}');
|
||||
} else {
|
||||
print('Robinhood Failed to fetch $action quote: ${response.statusCode}');
|
||||
printV('Robinhood Failed to fetch $action quote: ${response.statusCode}');
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ import 'dart:convert';
|
||||
import 'package:cake_wallet/cake_pay/cake_pay_order.dart';
|
||||
import 'package:cake_wallet/cake_pay/cake_pay_user_credentials.dart';
|
||||
import 'package:cake_wallet/cake_pay/cake_pay_vendor.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cake_wallet/entities/country.dart';
|
||||
import 'package:http/http.dart' as http;
|
||||
|
||||
@@ -140,7 +141,7 @@ class CakePayApi {
|
||||
|
||||
final response = await http.get(uri, headers: headers);
|
||||
|
||||
print('Response: ${response.statusCode}');
|
||||
printV('Response: ${response.statusCode}');
|
||||
|
||||
if (response.statusCode != 200) {
|
||||
throw Exception('Unexpected http status: ${response.statusCode}');
|
||||
@@ -167,7 +168,7 @@ class CakePayApi {
|
||||
throw Exception('Unexpected http status: ${response.statusCode}');
|
||||
}
|
||||
} catch (e) {
|
||||
print('Caught exception: $e');
|
||||
printV('Caught exception: $e');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ import 'package:cake_wallet/core/secure_storage.dart';
|
||||
import 'package:cake_wallet/core/totp_request_details.dart';
|
||||
import 'package:cake_wallet/routes.dart';
|
||||
import 'package:cake_wallet/src/screens/auth/auth_page.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
@@ -51,7 +52,7 @@ class AuthService with Store {
|
||||
try {
|
||||
password = await secureStorage.read(key: key) ?? '';
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
|
||||
return walletName.isNotEmpty && password.isNotEmpty;
|
||||
|
||||
@@ -7,6 +7,7 @@ import 'package:cake_wallet/entities/transaction_description.dart';
|
||||
import 'package:cake_wallet/themes/theme_list.dart';
|
||||
import 'package:cw_core/root_dir.dart';
|
||||
import 'package:cake_wallet/utils/device_info.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
@@ -110,11 +111,11 @@ class BackupService {
|
||||
for (var ignore in ignoreFiles) {
|
||||
final filename = entity.absolute.path;
|
||||
if (filename.endsWith(ignore) && !filename.contains("wallets/")) {
|
||||
print("ignoring backup file: $filename");
|
||||
printV("ignoring backup file: $filename");
|
||||
return;
|
||||
}
|
||||
}
|
||||
print("restoring: $filename");
|
||||
printV("restoring: $filename");
|
||||
if (entity.statSync().type == FileSystemEntityType.directory) {
|
||||
zipEncoder.addDirectory(Directory(entity.path));
|
||||
} else {
|
||||
@@ -175,11 +176,11 @@ class BackupService {
|
||||
final filename = file.name;
|
||||
for (var ignore in ignoreFiles) {
|
||||
if (filename.endsWith(ignore) && !filename.contains("wallets/")) {
|
||||
print("ignoring backup file: $filename");
|
||||
printV("ignoring backup file: $filename");
|
||||
continue outer;
|
||||
}
|
||||
}
|
||||
print("restoring: $filename");
|
||||
printV("restoring: $filename");
|
||||
if (file.isFile) {
|
||||
final content = file.content as List<int>;
|
||||
File('${appDir.path}/' + filename)
|
||||
@@ -193,7 +194,7 @@ class BackupService {
|
||||
await _verifyWallets();
|
||||
await _importKeychainDumpV2(password);
|
||||
await _importPreferencesDump();
|
||||
await _importTransactionDescriptionDump();
|
||||
await _importTransactionDescriptionDump(); // HiveError: Box has already been closed
|
||||
}
|
||||
|
||||
Future<void> _verifyWallets() async {
|
||||
|
||||
@@ -8,6 +8,7 @@ import 'package:cake_wallet/src/screens/wallet_connect/widgets/message_display_w
|
||||
import 'package:cake_wallet/core/wallet_connect/models/connection_model.dart';
|
||||
import 'package:cake_wallet/src/screens/wallet_connect/widgets/connection_widget.dart';
|
||||
import 'package:cake_wallet/src/screens/wallet_connect/widgets/modals/web3_request_modal.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:solana/base58.dart';
|
||||
import 'package:solana/solana.dart';
|
||||
import 'package:walletconnect_flutter_v2/walletconnect_flutter_v2.dart';
|
||||
@@ -127,7 +128,7 @@ class SolanaChainServiceImpl implements ChainService {
|
||||
commitment: Commitment.confirmed,
|
||||
);
|
||||
|
||||
print(signature);
|
||||
printV(signature);
|
||||
|
||||
bottomSheetService.queueBottomSheet(
|
||||
isModalDismissible: true,
|
||||
@@ -165,7 +166,7 @@ class SolanaChainServiceImpl implements ChainService {
|
||||
try {
|
||||
sign = await ownerKeyPair?.sign(base58decode(solanaSignMessage.message));
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
|
||||
if (sign == null) {
|
||||
|
||||
@@ -17,6 +17,7 @@ import 'package:cake_wallet/src/screens/wallet_connect/widgets/connection_reques
|
||||
import 'package:cake_wallet/src/screens/wallet_connect/widgets/message_display_widget.dart';
|
||||
import 'package:cake_wallet/src/screens/wallet_connect/widgets/modals/web3_request_modal.dart';
|
||||
import 'package:cake_wallet/store/app_store.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:eth_sig_util/eth_sig_util.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -260,7 +261,7 @@ abstract class Web3WalletServiceBase with Store {
|
||||
|
||||
@action
|
||||
void _refreshPairings() {
|
||||
print('Refreshing pairings');
|
||||
printV('Refreshing pairings');
|
||||
pairings.clear();
|
||||
|
||||
final allPairings = _web3Wallet.pairings.getAll();
|
||||
@@ -397,10 +398,10 @@ abstract class Web3WalletServiceBase with Store {
|
||||
// Get all pairing topics attached to this key
|
||||
final pairingTopicsForWallet = getPairingTopicsForWallet(key);
|
||||
|
||||
print(pairingTopicsForWallet);
|
||||
printV(pairingTopicsForWallet);
|
||||
|
||||
bool isPairingTopicAlreadySaved = pairingTopicsForWallet.contains(pairingTopic);
|
||||
print('Is Pairing Topic Saved: $isPairingTopicAlreadySaved');
|
||||
printV('Is Pairing Topic Saved: $isPairingTopicAlreadySaved');
|
||||
|
||||
if (!isPairingTopicAlreadySaved) {
|
||||
// Update the list with the most recent pairing topic
|
||||
|
||||
@@ -12,6 +12,7 @@ import 'package:cake_wallet/src/widgets/alert_with_two_actions.dart';
|
||||
import 'package:cake_wallet/utils/exception_handler.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:cw_core/cake_hive.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_info.dart';
|
||||
import 'package:cw_core/wallet_service.dart';
|
||||
@@ -97,7 +98,7 @@ class WalletLoadingService {
|
||||
// if found a wallet that is not corrupted, then still display the seeds of the corrupted ones
|
||||
authenticatedErrorStreamController.add(corruptedWalletsSeeds);
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
// save seeds and show corrupted wallets' seeds to the user
|
||||
try {
|
||||
final seeds = await _getCorruptedWalletSeeds(walletInfo.name, walletInfo.type);
|
||||
|
||||
@@ -8,6 +8,7 @@ import 'package:cake_wallet/utils/feature_flag.dart';
|
||||
import 'package:cake_wallet/view_model/settings/sync_mode.dart';
|
||||
import 'package:cake_wallet/view_model/wallet_list/wallet_list_item.dart';
|
||||
import 'package:cake_wallet/view_model/wallet_list/wallet_list_view_model.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
@@ -83,8 +84,8 @@ void callbackDispatcher() {
|
||||
|
||||
return Future.value(true);
|
||||
} catch (error, stackTrace) {
|
||||
print(error);
|
||||
print(stackTrace);
|
||||
printV(error);
|
||||
printV(stackTrace);
|
||||
return Future.error(error);
|
||||
}
|
||||
});
|
||||
@@ -149,8 +150,8 @@ class BackgroundTasks {
|
||||
constraints: constraints,
|
||||
);
|
||||
} catch (error, stackTrace) {
|
||||
print(error);
|
||||
print(stackTrace);
|
||||
printV(error);
|
||||
printV(stackTrace);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -158,8 +159,8 @@ class BackgroundTasks {
|
||||
try {
|
||||
Workmanager().cancelByUniqueName(moneroSyncTaskKey);
|
||||
} catch (error, stackTrace) {
|
||||
print(error);
|
||||
print(stackTrace);
|
||||
printV(error);
|
||||
printV(stackTrace);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_local_authentication/flutter_local_authentication.dart';
|
||||
|
||||
@@ -9,7 +10,7 @@ class BiometricAuth {
|
||||
final authenticated = await _flutterLocalAuthenticationPlugin.authenticate();
|
||||
return authenticated;
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
@@ -20,7 +21,7 @@ class BiometricAuth {
|
||||
canAuthenticate = await _flutterLocalAuthenticationPlugin.canAuthenticate();
|
||||
await _flutterLocalAuthenticationPlugin.setTouchIDAuthenticationAllowableReuseDuration(0);
|
||||
} catch (error) {
|
||||
print("Exception checking support. $error");
|
||||
printV("Exception checking support. $error");
|
||||
canAuthenticate = false;
|
||||
}
|
||||
|
||||
|
||||
@@ -7,6 +7,7 @@ import 'package:cake_wallet/entities/fiat_api_mode.dart';
|
||||
import 'package:cw_core/pathForWallet.dart';
|
||||
import 'package:cake_wallet/entities/secret_store_key.dart';
|
||||
import 'package:cw_core/root_dir.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
import 'package:cake_wallet/entities/preferences_key.dart';
|
||||
@@ -296,7 +297,7 @@ Future<void> defaultSettingsMigration(
|
||||
await sharedPreferences.setInt(
|
||||
PreferencesKey.currentDefaultSettingsMigrationVersion, version);
|
||||
} catch (e) {
|
||||
print('Migration error: ${e.toString()}');
|
||||
printV('Migration error: ${e.toString()}');
|
||||
}
|
||||
});
|
||||
|
||||
@@ -714,7 +715,7 @@ Future<void> insecureStorageMigration({
|
||||
await secureStorage.write(
|
||||
key: SecureKey.lastAuthTimeMilliseconds, value: lastAuthTimeMilliseconds.toString());
|
||||
} catch (e) {
|
||||
print("Error migrating shared preferences to secure storage!: $e");
|
||||
printV("Error migrating shared preferences to secure storage!: $e");
|
||||
// this actually shouldn't be that big of a problem since we don't delete the old keys in this update
|
||||
// and we read and write to the new locations when loading storage, the migration is just for extra safety
|
||||
}
|
||||
@@ -870,7 +871,7 @@ Future<void> addAddressesForMoneroWallets(Box<WalletInfo> walletInfoSource) asyn
|
||||
info.address = addressText;
|
||||
await info.save();
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import 'package:cake_wallet/ethereum/ethereum.dart';
|
||||
import 'package:cake_wallet/polygon/polygon.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:ens_dart/ens_dart.dart';
|
||||
@@ -45,7 +46,7 @@ class EnsRecord {
|
||||
final addr = await ens.withName(name).getAddress();
|
||||
return addr.hex;
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@ import 'dart:io';
|
||||
import 'dart:convert';
|
||||
import 'package:cake_wallet/core/secure_storage.dart';
|
||||
import 'package:collection/collection.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
import 'package:path_provider/path_provider.dart';
|
||||
@@ -171,7 +172,7 @@ Future<void> ios_migrate_wallet_passwords() async {
|
||||
await keyService.saveWalletPassword(walletName: name, password: password!);
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
});
|
||||
|
||||
@@ -326,7 +327,7 @@ Future<void> ios_migrate_wallet_info(Box<WalletInfo> walletsInfoSource) async {
|
||||
return walletInfo;
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
return null;
|
||||
}
|
||||
})
|
||||
@@ -336,7 +337,7 @@ Future<void> ios_migrate_wallet_info(Box<WalletInfo> walletsInfoSource) async {
|
||||
await walletsInfoSource.addAll(infoRecords);
|
||||
await prefs.setBool('ios_migration_wallet_info_completed', true);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -403,7 +404,7 @@ Future<void> ios_migrate_trades_list(Box<Trade> tradeSource) async {
|
||||
await tradeSource.addAll(trades);
|
||||
await prefs.setBool('ios_migration_trade_list_completed', true);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -437,6 +438,6 @@ Future<void> ios_migrate_address_book(Box<Contact> contactSource) async {
|
||||
await contactSource.addAll(contacts);
|
||||
await prefs.setBool('ios_migration_address_book_completed', true);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import 'package:basic_utils/basic_utils.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
|
||||
class OpenaliasRecord {
|
||||
OpenaliasRecord({
|
||||
@@ -27,7 +28,7 @@ class OpenaliasRecord {
|
||||
|
||||
return txtRecord;
|
||||
} catch (e) {
|
||||
print("${e.toString()}");
|
||||
printV("${e.toString()}");
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ import 'package:cake_wallet/nostr/nostr_api.dart';
|
||||
import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/twitter/twitter_api.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:cake_wallet/entities/fio_address_provider.dart';
|
||||
@@ -283,7 +284,7 @@ class AddressResolver {
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
|
||||
return ParsedAddress(addresses: [text]);
|
||||
|
||||
@@ -5,6 +5,7 @@ import 'package:cake_wallet/main.dart';
|
||||
import 'package:cake_wallet/src/widgets/alert_with_one_action.dart';
|
||||
import 'package:cake_wallet/src/widgets/alert_with_two_actions.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:fast_scanner/fast_scanner.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/scheduler.dart';
|
||||
@@ -61,7 +62,7 @@ class _BarcodeScannerSimpleState extends State<BarcodeScannerSimple> {
|
||||
);
|
||||
},
|
||||
);
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import 'dart:convert';
|
||||
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:http/http.dart' as http;
|
||||
|
||||
Future<String> fetchUnstoppableDomainAddress(String domain, String ticker) async {
|
||||
@@ -20,7 +21,7 @@ Future<String> fetchUnstoppableDomainAddress(String domain, String ticker) async
|
||||
|
||||
return records[key] as String? ?? '';
|
||||
} catch (e) {
|
||||
print('Unstoppable domain error: ${e.toString()}');
|
||||
printV('Unstoppable domain error: ${e.toString()}');
|
||||
address = '';
|
||||
}
|
||||
|
||||
|
||||
@@ -205,7 +205,7 @@ class CWEthereum extends Ethereum {
|
||||
try {
|
||||
return await hardwareWalletService.getAvailableAccounts(index: index, limit: limit);
|
||||
} catch (err) {
|
||||
print(err);
|
||||
printV(err);
|
||||
throw err;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,6 +15,7 @@ import 'package:cake_wallet/utils/device_info.dart';
|
||||
import 'package:cake_wallet/utils/distribution_info.dart';
|
||||
import 'package:cake_wallet/wallet_type_utils.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:http/http.dart';
|
||||
|
||||
class ChangeNowExchangeProvider extends ExchangeProvider {
|
||||
@@ -127,7 +128,7 @@ class ChangeNowExchangeProvider extends ExchangeProvider {
|
||||
|
||||
return isReverse ? (amount / fromAmount) : (toAmount / amount);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
return 0.0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,6 +10,7 @@ import 'package:cake_wallet/exchange/trade_request.dart';
|
||||
import 'package:cake_wallet/exchange/trade_state.dart';
|
||||
import 'package:cake_wallet/exchange/utils/currency_pairs_utils.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:http/http.dart';
|
||||
|
||||
class ExolixExchangeProvider extends ExchangeProvider {
|
||||
@@ -124,7 +125,7 @@ class ExolixExchangeProvider extends ExchangeProvider {
|
||||
|
||||
return responseJSON['rate'] as double;
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
return 0.0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ import 'package:cake_wallet/exchange/trade_request.dart';
|
||||
import 'package:cake_wallet/exchange/trade_state.dart';
|
||||
import 'package:cake_wallet/exchange/utils/currency_pairs_utils.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:http/http.dart';
|
||||
|
||||
class QuantexExchangeProvider extends ExchangeProvider {
|
||||
@@ -86,7 +87,7 @@ class QuantexExchangeProvider extends ExchangeProvider {
|
||||
// coin not found:
|
||||
return Limits(min: 0, max: 0);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
return Limits(min: 0, max: 0);
|
||||
}
|
||||
}
|
||||
@@ -121,7 +122,7 @@ class QuantexExchangeProvider extends ExchangeProvider {
|
||||
double rate = double.parse(data['price'].toString());
|
||||
return rate;
|
||||
} catch (e) {
|
||||
print("error fetching rate: ${e.toString()}");
|
||||
printV("error fetching rate: ${e.toString()}");
|
||||
return 0.0;
|
||||
}
|
||||
}
|
||||
@@ -178,7 +179,7 @@ class QuantexExchangeProvider extends ExchangeProvider {
|
||||
isSendAll: isSendAll,
|
||||
);
|
||||
} catch (e) {
|
||||
print("error creating trade: ${e.toString()}");
|
||||
printV("error creating trade: ${e.toString()}");
|
||||
throw TradeNotCreatedException(description, description: e.toString());
|
||||
}
|
||||
}
|
||||
@@ -225,7 +226,7 @@ class QuantexExchangeProvider extends ExchangeProvider {
|
||||
state: state,
|
||||
);
|
||||
} catch (e) {
|
||||
print("error getting trade: ${e.toString()}");
|
||||
printV("error getting trade: ${e.toString()}");
|
||||
throw TradeNotFoundException(
|
||||
id,
|
||||
provider: description,
|
||||
|
||||
@@ -8,6 +8,7 @@ import 'package:cake_wallet/exchange/trade_request.dart';
|
||||
import 'package:cake_wallet/exchange/trade_state.dart';
|
||||
import 'package:cake_wallet/exchange/utils/currency_pairs_utils.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
import 'package:http/http.dart' as http;
|
||||
|
||||
@@ -86,7 +87,7 @@ class ThorChainExchangeProvider extends ExchangeProvider {
|
||||
|
||||
return _thorChainAmountToDouble(expectedAmountOut) / amount;
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
return 0.0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@ import 'package:cake_wallet/exchange/trade_request.dart';
|
||||
import 'package:cake_wallet/exchange/trade_state.dart';
|
||||
import 'package:cake_wallet/exchange/utils/currency_pairs_utils.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:http/http.dart';
|
||||
|
||||
class TrocadorExchangeProvider extends ExchangeProvider {
|
||||
@@ -148,7 +149,7 @@ class TrocadorExchangeProvider extends ExchangeProvider {
|
||||
|
||||
return isReceiveAmount ? (amount / fromAmount) : (toAmount / amount);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
return 0.0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import 'dart:convert';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:http/http.dart' as http;
|
||||
import 'package:cake_wallet/mastodon/mastodon_user.dart';
|
||||
|
||||
@@ -27,7 +28,7 @@ class MastodonAPI {
|
||||
|
||||
return MastodonUser.fromJson(responseJSON);
|
||||
} catch (e) {
|
||||
print('Error in lookupUserByUserName: $e');
|
||||
printV('Error in lookupUserByUserName: $e');
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -56,7 +57,7 @@ class MastodonAPI {
|
||||
|
||||
return responseJSON.map((json) => PinnedPost.fromJson(json as Map<String, dynamic>)).toList();
|
||||
} catch (e) {
|
||||
print('Error in getPinnedPosts: $e');
|
||||
printV('Error in getPinnedPosts: $e');
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -249,7 +249,7 @@ class CWNanoUtil extends NanoUtil {
|
||||
try {
|
||||
mnemonic = NanoDerivations.standardSeedToMnemonic(seedKey);
|
||||
} catch (e) {
|
||||
print("not a valid 'nano' seed key");
|
||||
printV("not a valid 'nano' seed key");
|
||||
}
|
||||
}
|
||||
if (derivationType == DerivationType.bip39) {
|
||||
@@ -306,7 +306,7 @@ class CWNanoUtil extends NanoUtil {
|
||||
try {
|
||||
mnemonic = NanoDerivations.standardSeedToMnemonic(seedKey!);
|
||||
} catch (e) {
|
||||
print("not a valid 'nano' seed key");
|
||||
printV("not a valid 'nano' seed key");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@ import 'package:cake_wallet/nostr/nostr_user.dart';
|
||||
import 'package:cake_wallet/src/widgets/alert_with_one_action.dart';
|
||||
import 'package:cake_wallet/src/widgets/picker.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:nostr_tools/nostr_tools.dart';
|
||||
|
||||
@@ -83,7 +84,7 @@ class NostrProfileHandler {
|
||||
relay.close();
|
||||
return null;
|
||||
} catch (e) {
|
||||
print('[!] Error with relay $relayUrl: $e');
|
||||
printV('[!] Error with relay $relayUrl: $e');
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -115,7 +116,7 @@ class NostrProfileHandler {
|
||||
var uri = Uri.parse(relayUrl);
|
||||
return uri.host;
|
||||
} catch (e) {
|
||||
print('Error parsing URL: $e');
|
||||
printV('Error parsing URL: $e');
|
||||
return '';
|
||||
}
|
||||
}
|
||||
|
||||
@@ -204,7 +204,7 @@ class CWPolygon extends Polygon {
|
||||
try {
|
||||
return await hardwareWalletService.getAvailableAccounts(index: index, limit: limit);
|
||||
} catch (err) {
|
||||
print(err);
|
||||
printV(err);
|
||||
throw err;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:connectivity_plus/connectivity_plus.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/sync_status.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
@@ -36,7 +37,7 @@ void startCheckConnectionReaction(WalletBase wallet, SettingsStore settingsStore
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/tron/tron.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/erc20_token.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
|
||||
@@ -71,7 +72,7 @@ Future<void> startFiatRateUpdate(
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:cw_core/node.dart';
|
||||
import 'package:cake_wallet/store/app_store.dart';
|
||||
@@ -10,14 +11,14 @@ void startOnCurrentNodeChangeReaction(AppStore appStore) {
|
||||
try {
|
||||
await appStore.wallet!.connectToNode(node: change.newValue!);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
});
|
||||
appStore.settingsStore.powNodes.observe((change) async {
|
||||
try {
|
||||
await appStore.wallet!.connectToPowNode(node: change.newValue!);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@ import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/transaction_history.dart';
|
||||
import 'package:cw_core/balance.dart';
|
||||
import 'package:cw_core/transaction_info.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:cake_wallet/reactions/check_connection.dart';
|
||||
import 'package:cake_wallet/reactions/on_wallet_sync_status_change.dart';
|
||||
@@ -46,7 +47,7 @@ void startCurrentWalletChangeReaction(
|
||||
// appStore.wallet.walletInfo.yatLastUsedAddress = address;
|
||||
// await appStore.wallet.walletInfo.save();
|
||||
//} catch (e) {
|
||||
// print(e.toString());
|
||||
// printV(e.toString());
|
||||
//}
|
||||
//});
|
||||
|
||||
@@ -91,7 +92,7 @@ void startCurrentWalletChangeReaction(
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
});
|
||||
|
||||
@@ -138,7 +139,7 @@ void startCurrentWalletChangeReaction(
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import 'package:cake_wallet/entities/update_haven_rate.dart';
|
||||
import 'package:cake_wallet/store/dashboard/fiat_conversion_store.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:cw_core/transaction_history.dart';
|
||||
@@ -31,7 +32,7 @@ void startWalletSyncStatusChangeReaction(
|
||||
await WakelockPlus.disable();
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@ import 'package:cake_wallet/generated/i18n.dart';
|
||||
import 'package:cake_wallet/src/screens/base_page.dart';
|
||||
import 'package:cake_wallet/store/dashboard/orders_store.dart';
|
||||
import 'package:cake_wallet/view_model/buy/buy_view_model.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_inappwebview/flutter_inappwebview.dart';
|
||||
|
||||
@@ -103,7 +104,7 @@ class BuyWebViewPageBodyState extends State<BuyWebViewPageBody> {
|
||||
}
|
||||
} catch (e) {
|
||||
_isSaving = false;
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -10,6 +10,7 @@ import 'package:cake_wallet/themes/extensions/cake_text_theme.dart';
|
||||
import 'package:cake_wallet/themes/extensions/wallet_list_theme.dart';
|
||||
import 'package:cake_wallet/utils/responsive_layout_util.dart';
|
||||
import 'package:cake_wallet/view_model/hardware_wallet/ledger_view_model.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_mobx/flutter_mobx.dart';
|
||||
@@ -127,7 +128,7 @@ class ConnectDevicePageBodyState extends State<ConnectDevicePageBody> {
|
||||
_bleRefreshTimer = null;
|
||||
}
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -223,10 +223,10 @@
|
||||
// setState(() => status = "Sending...");
|
||||
// final acc = await func();
|
||||
// setState(() => status = "$method: $acc");
|
||||
// print("$method: $acc");
|
||||
// printV("$method: $acc");
|
||||
// } on LedgerException catch (ex) {
|
||||
// setState(() => status = "${ex.errorCode.toRadixString(16)} ${ex.message}");
|
||||
// print("${ex.errorCode.toRadixString(16)} ${ex.message}");
|
||||
// printV("${ex.errorCode.toRadixString(16)} ${ex.message}");
|
||||
// }
|
||||
// },
|
||||
// color: Theme.of(context).primaryColor,
|
||||
|
||||
@@ -7,6 +7,7 @@ import 'package:cake_wallet/src/widgets/dashboard_card_widget.dart';
|
||||
import 'package:cake_wallet/themes/extensions/dashboard_page_theme.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:cake_wallet/view_model/dashboard/dashboard_view_model.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:cake_wallet/view_model/dashboard/cake_features_view_model.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -105,7 +106,7 @@ class CakeFeaturesPage extends StatelessWidget {
|
||||
mode: LaunchMode.externalApplication,
|
||||
);
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ import 'package:cake_wallet/core/auth_service.dart';
|
||||
import 'package:cake_wallet/core/totp_request_details.dart';
|
||||
import 'package:cake_wallet/utils/device_info.dart';
|
||||
import 'package:cake_wallet/view_model/link_view_model.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -91,7 +92,7 @@ class RootState extends State<Root> with WidgetsBindingObserver {
|
||||
|
||||
handleDeepLinking(await getInitialUri());
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -28,6 +28,7 @@ import 'package:cake_wallet/utils/request_review_handler.dart';
|
||||
import 'package:cake_wallet/utils/responsive_layout_util.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:cake_wallet/view_model/send/output.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/unspent_coin_type.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:cake_wallet/view_model/send/send_view_model.dart';
|
||||
@@ -584,7 +585,7 @@ class SendPage extends BasePage {
|
||||
mode: LaunchMode.externalApplication,
|
||||
);
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ import 'dart:io';
|
||||
|
||||
import 'package:cake_wallet/src/screens/base_page.dart';
|
||||
import 'package:cake_wallet/store/app_store.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
// import 'package:tor/tor.dart';
|
||||
|
||||
@@ -57,7 +58,7 @@ class _TorPageBodyState extends State<TorPageBody> {
|
||||
// }
|
||||
// widget.appStore.wallet!.connectToNode(node: node);
|
||||
|
||||
print('Done awaiting; tor should be running');
|
||||
printV('Done awaiting; tor should be running');
|
||||
}
|
||||
|
||||
Future<void> endTor() async {
|
||||
@@ -69,7 +70,7 @@ class _TorPageBodyState extends State<TorPageBody> {
|
||||
// torEnabled = Tor.instance.enabled; // Update flag
|
||||
// });
|
||||
//
|
||||
// print('Done awaiting; tor should be stopped');
|
||||
// printV('Done awaiting; tor should be stopped');
|
||||
}
|
||||
//
|
||||
// @override
|
||||
|
||||
@@ -3,6 +3,7 @@ import 'package:cake_wallet/core/execution_state.dart';
|
||||
import 'package:cake_wallet/core/totp_request_details.dart';
|
||||
import 'package:cake_wallet/utils/show_bar.dart';
|
||||
import 'package:cake_wallet/view_model/auth_state.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import 'package:cake_wallet/generated/i18n.dart';
|
||||
@@ -53,7 +54,7 @@ class TotpAuthCodePageState extends State<TotpAuthCodePage> {
|
||||
}
|
||||
|
||||
if (state is FailureState) {
|
||||
print(state.error);
|
||||
printV(state.error);
|
||||
widget.totpArguments.onTotpAuthenticationFinished!(false, this);
|
||||
}
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@ import 'package:cake_wallet/generated/i18n.dart';
|
||||
import 'package:cake_wallet/src/screens/base_page.dart';
|
||||
import 'package:cake_wallet/src/screens/support_chat/widgets/chatwoot_widget.dart';
|
||||
import 'package:cake_wallet/view_model/support_view_model.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
|
||||
@@ -22,7 +23,7 @@ class SupportChatPage extends BasePage {
|
||||
Widget body(BuildContext context) => FutureBuilder<String>(
|
||||
future: getCookie(),
|
||||
builder: (BuildContext context, AsyncSnapshot<String> snapshot) {
|
||||
print(snapshot.data);
|
||||
printV(snapshot.data);
|
||||
if (snapshot.hasData)
|
||||
return ChatwootWidget(
|
||||
secureStorage,
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import 'dart:convert';
|
||||
|
||||
import 'package:cake_wallet/core/secure_storage.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_inappwebview/flutter_inappwebview.dart';
|
||||
|
||||
@@ -38,7 +39,7 @@ class ChatwootWidgetState extends State<ChatwootWidget> {
|
||||
final eventType = parsedMessage["event"];
|
||||
if (eventType == 'loaded') {
|
||||
final authToken = parsedMessage["config"]["authToken"];
|
||||
print(authToken);
|
||||
printV(authToken);
|
||||
storeCookie(authToken as String);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -36,6 +36,7 @@ import 'package:cake_wallet/wownero/wownero.dart';
|
||||
import 'package:cw_core/node.dart';
|
||||
import 'package:cw_core/set_app_secure_native.dart';
|
||||
import 'package:cw_core/transaction_priority.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:device_info_plus/device_info_plus.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -1663,8 +1664,8 @@ abstract class SettingsStoreBase with Store {
|
||||
final windowsInfo = await deviceInfoPlugin.windowsInfo;
|
||||
deviceName = windowsInfo.productName;
|
||||
} catch (e) {
|
||||
print(e);
|
||||
print(
|
||||
printV(e);
|
||||
printV(
|
||||
'likely digitalProductId is null wait till https://github.com/fluttercommunity/plus_plugins/pull/3188 is merged');
|
||||
deviceName = "Windows Device";
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import 'package:cake_wallet/core/secure_storage.dart';
|
||||
import 'package:cw_core/transaction_history.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/balance.dart';
|
||||
import 'package:cw_core/transaction_info.dart';
|
||||
@@ -250,7 +251,7 @@ abstract class YatStoreBase with Store {
|
||||
walletInfo!.save();
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -265,7 +266,7 @@ abstract class YatStoreBase with Store {
|
||||
// apiKey = await fetchYatApiKey(accessToken);
|
||||
// await secureStorage.write(key: yatApiKey(_wallet.walletInfo.name), value: accessToken);
|
||||
//} catch (e) {
|
||||
// print(e.toString());
|
||||
// printV(e.toString());
|
||||
//}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import 'dart:io';
|
||||
import 'package:cake_wallet/utils/package_info.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
|
||||
enum DistributionType { googleplay, github, appstore, fdroid }
|
||||
|
||||
@@ -32,7 +33,7 @@ class DistributionInfo {
|
||||
final packageInfo = await PackageInfo.fromPlatform();
|
||||
return packageInfo.packageName == 'com.android.vending';
|
||||
} catch (e) {
|
||||
print('Error: $e');
|
||||
printV('Error: $e');
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,6 +7,7 @@ import 'package:cake_wallet/src/widgets/alert_with_two_actions.dart';
|
||||
import 'package:cake_wallet/utils/show_bar.dart';
|
||||
import 'package:cake_wallet/utils/show_pop_up.dart';
|
||||
import 'package:cw_core/root_dir.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:device_info_plus/device_info_plus.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
@@ -67,7 +68,7 @@ class ExceptionHandler {
|
||||
final bool canSend = await FlutterMailer.canSendMail();
|
||||
|
||||
if (Platform.isIOS && !canSend) {
|
||||
debugPrint('Mail app is not available');
|
||||
printV('Mail app is not available');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -99,7 +100,7 @@ class ExceptionHandler {
|
||||
static Future<void> onError(FlutterErrorDetails errorDetails) async {
|
||||
if (kDebugMode || kProfileMode) {
|
||||
FlutterError.presentError(errorDetails);
|
||||
debugPrint(errorDetails.toString());
|
||||
printV(errorDetails.toString());
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@ import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/utils/date_formatter.dart';
|
||||
import 'package:cake_wallet/utils/show_bar.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
@@ -47,7 +48,7 @@ abstract class AnonpayDetailsViewModelBase with Store {
|
||||
invoiceDetail.status = data.status;
|
||||
_updateItems();
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@ import 'package:cake_wallet/core/secure_storage.dart';
|
||||
import 'package:cake_wallet/entities/secret_store_key.dart';
|
||||
import 'package:cake_wallet/store/secret_store.dart';
|
||||
import 'package:cw_core/root_dir.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:intl/intl.dart';
|
||||
@@ -67,7 +68,7 @@ abstract class BackupViewModelBase with Store {
|
||||
|
||||
return BackupExportFile(backupContent.toList(), name: fileName);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
state = FailureState(e.toString());
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@ import 'package:cake_wallet/buy/buy_amount.dart';
|
||||
import 'package:cake_wallet/buy/buy_provider.dart';
|
||||
import 'package:cake_wallet/entities/fiat_currency.dart';
|
||||
import 'package:cake_wallet/view_model/buy/buy_amount_view_model.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
|
||||
class BuyItem {
|
||||
BuyItem({required this.provider, required this.buyAmountViewModel});
|
||||
@@ -21,7 +22,7 @@ class BuyItem {
|
||||
.calculateAmount(amount?.toString() ?? '', fiatCurrency.title);
|
||||
} catch (e) {
|
||||
_buyAmount = BuyAmount(sourceAmount: 0.0, destAmount: 0.0);
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
|
||||
return _buyAmount;
|
||||
|
||||
@@ -3,6 +3,7 @@ import 'package:cake_wallet/buy/moonpay/moonpay_provider.dart';
|
||||
import 'package:cake_wallet/buy/wyre/wyre_buy_provider.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cake_wallet/entities/fiat_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/view_model/buy/buy_item.dart';
|
||||
@@ -63,7 +64,7 @@ abstract class BuyViewModelBase with Store {
|
||||
try {
|
||||
_url = await selectedProvider!.requestUrl(doubleAmount.toString(), fiatCurrency.title);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
|
||||
return _url;
|
||||
@@ -77,7 +78,7 @@ abstract class BuyViewModelBase with Store {
|
||||
await ordersSource.add(order);
|
||||
ordersStore.setOrder(order);
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -15,6 +15,7 @@ import 'package:cake_wallet/tron/tron.dart';
|
||||
import 'package:cake_wallet/view_model/dashboard/balance_view_model.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/erc20_token.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:http/http.dart' as http;
|
||||
@@ -236,7 +237,7 @@ abstract class HomeSettingsViewModelBase with Store {
|
||||
|
||||
return false;
|
||||
} catch (e) {
|
||||
print('Error while checking scam via moralis: ${e.toString()}');
|
||||
printV('Error while checking scam via moralis: ${e.toString()}');
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -277,7 +278,7 @@ abstract class HomeSettingsViewModelBase with Store {
|
||||
|
||||
return false;
|
||||
} catch (e) {
|
||||
print('Error while checking scam via explorers: ${e.toString()}');
|
||||
printV('Error while checking scam via explorers: ${e.toString()}');
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -303,21 +304,21 @@ abstract class HomeSettingsViewModelBase with Store {
|
||||
final decodedResponse = jsonDecode(response.body) as Map<String, dynamic>;
|
||||
|
||||
if (decodedResponse['status'] == '0') {
|
||||
print('${response.body}\n');
|
||||
print('${decodedResponse['result']}\n');
|
||||
printV('${response.body}\n');
|
||||
printV('${decodedResponse['result']}\n');
|
||||
return true;
|
||||
}
|
||||
|
||||
if (decodedResponse['status'] == '1' &&
|
||||
decodedResponse['result'][0]['ABI'] == 'Contract source code not verified') {
|
||||
print('Call is valid but contract is not verified');
|
||||
printV('Call is valid but contract is not verified');
|
||||
return true; // Contract is not verified
|
||||
} else {
|
||||
print('Call is valid and contract is verified');
|
||||
printV('Call is valid and contract is verified');
|
||||
return false; // Contract is verified
|
||||
}
|
||||
} catch (e) {
|
||||
print('Error while checking contract verification: ${e.toString()}');
|
||||
printV('Error while checking contract verification: ${e.toString()}');
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@ import 'package:cake_wallet/src/screens/exchange_trade/exchange_trade_item.dart'
|
||||
import 'package:cake_wallet/store/dashboard/trades_store.dart';
|
||||
import 'package:cake_wallet/view_model/send/send_view_model.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
@@ -139,7 +140,7 @@ abstract class ExchangeTradeViewModelBase with Store {
|
||||
|
||||
_updateItems();
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -9,6 +9,7 @@ import 'package:cake_wallet/exchange/provider/stealth_ex_exchange_provider.dart'
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/sync_status.dart';
|
||||
import 'package:cw_core/transaction_priority.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
import 'package:http/http.dart' as http;
|
||||
@@ -944,7 +945,7 @@ abstract class ExchangeViewModelBase extends WalletChangeListenerViewModel with
|
||||
|
||||
return isContractAddress;
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@ import 'package:cake_wallet/polygon/polygon.dart';
|
||||
import 'package:cake_wallet/utils/device_info.dart';
|
||||
import 'package:cake_wallet/wallet_type_utils.dart';
|
||||
import 'package:cw_core/hardware/device_connection_type.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
|
||||
@@ -95,7 +96,7 @@ abstract class LedgerViewModelBase with Store {
|
||||
|
||||
if (_connectionChangeListener == null) {
|
||||
_connectionChangeListener = ledger.deviceStateChanges.listen((event) {
|
||||
print('Ledger Device State Changed: $event');
|
||||
printV('Ledger Device State Changed: $event');
|
||||
if (event == sdk.BleConnectionState.disconnected) {
|
||||
_connection = null;
|
||||
if (type == WalletType.monero) {
|
||||
|
||||
@@ -3,6 +3,7 @@ import 'package:cake_wallet/buy/buy_provider.dart';
|
||||
import 'package:cake_wallet/buy/buy_provider_description.dart';
|
||||
import 'package:cake_wallet/buy/order.dart';
|
||||
import 'package:cake_wallet/utils/date_formatter.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:cake_wallet/generated/i18n.dart';
|
||||
import 'package:cake_wallet/src/screens/transaction_details/standart_list_item.dart';
|
||||
@@ -65,7 +66,7 @@ abstract class OrderDetailsViewModelBase with Store {
|
||||
_updateItems();
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@ import 'package:cake_wallet/src/screens/send/widgets/extract_address_from_parsed
|
||||
import 'package:cake_wallet/tron/tron.dart';
|
||||
import 'package:cake_wallet/wownero/wownero.dart';
|
||||
import 'package:cw_core/crypto_currency.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:intl/intl.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
@@ -180,7 +181,7 @@ abstract class OutputBase with Store {
|
||||
return polygon!.formatterPolygonAmountToDouble(amount: BigInt.from(fee));
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
@@ -27,6 +27,7 @@ import 'package:cw_core/transaction_priority.dart';
|
||||
import 'package:cw_core/unspent_coin_type.dart';
|
||||
import 'package:cake_wallet/view_model/send/output.dart';
|
||||
import 'package:cake_wallet/view_model/send/send_template_view_model.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
@@ -672,7 +673,7 @@ abstract class SendViewModelBase extends WalletChangeListenerViewModel with Stor
|
||||
lamportsNeeded != null ? ((lamportsNeeded + 5000) / lamportsPerSol) : 0.0;
|
||||
return S.current.insufficient_lamports(solValueNeeded.toString());
|
||||
} else {
|
||||
print("No match found.");
|
||||
printV("No match found.");
|
||||
return S.current.insufficient_lamport_for_tx;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,6 +22,7 @@ import 'package:cake_wallet/store/settings_store.dart';
|
||||
import 'package:cake_wallet/utils/date_formatter.dart';
|
||||
import 'package:cake_wallet/utils/show_bar.dart';
|
||||
import 'package:collection/collection.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:hive/hive.dart';
|
||||
@@ -134,7 +135,7 @@ abstract class TradeDetailsViewModelBase with Store {
|
||||
|
||||
_updateItems();
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import 'package:cake_wallet/tron/tron.dart';
|
||||
import 'package:cake_wallet/wownero/wownero.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/transaction_info.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
@@ -279,7 +280,7 @@ abstract class TransactionDetailsViewModelBase with Store {
|
||||
));
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -769,7 +770,7 @@ abstract class TransactionDetailsViewModelBase with Store {
|
||||
);
|
||||
}
|
||||
} catch (e) {
|
||||
print(e.toString());
|
||||
printV(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ import 'package:cake_wallet/wownero/wownero.dart';
|
||||
import 'package:cw_core/unspent_coin_type.dart';
|
||||
import 'package:cw_core/unspent_coins_info.dart';
|
||||
import 'package:cw_core/unspent_transaction_output.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_type.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
@@ -82,7 +83,7 @@ abstract class UnspentCoinsListViewModelBase with Store {
|
||||
await existingInfo.save();
|
||||
_updateUnspentCoinsInfo();
|
||||
} catch (e) {
|
||||
print('Error saving coin info: $e');
|
||||
printV('Error saving coin info: $e');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -151,7 +152,7 @@ abstract class UnspentCoinsListViewModelBase with Store {
|
||||
isSilentPayment: existingItem.isSilentPayment ?? false,
|
||||
);
|
||||
} catch (e, s) {
|
||||
print('Error: $e\nStack: $s');
|
||||
printV('Error: $e\nStack: $s');
|
||||
ExceptionHandler.onError(
|
||||
FlutterErrorDetails(exception: e, stack: s),
|
||||
);
|
||||
|
||||
@@ -12,6 +12,7 @@ import 'package:cake_wallet/view_model/restore/restore_mode.dart';
|
||||
import 'package:cake_wallet/view_model/restore/restore_wallet.dart';
|
||||
import 'package:cake_wallet/view_model/seed_settings_view_model.dart';
|
||||
import 'package:cw_core/pathForWallet.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_credentials.dart';
|
||||
import 'package:cw_core/wallet_info.dart';
|
||||
@@ -116,8 +117,8 @@ abstract class WalletCreationVMBase with Store {
|
||||
_appStore.authenticationStore.allowed();
|
||||
state = ExecutedSuccessfullyState();
|
||||
} catch (e, s) {
|
||||
print("error: $e");
|
||||
print("stack: $s");
|
||||
printV("error: $e");
|
||||
printV("stack: $s");
|
||||
state = FailureState(e.toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,6 +10,7 @@ import 'package:cake_wallet/view_model/hardware_wallet/ledger_view_model.dart';
|
||||
import 'package:cake_wallet/view_model/seed_settings_view_model.dart';
|
||||
import 'package:cake_wallet/view_model/wallet_creation_vm.dart';
|
||||
import 'package:cw_core/hardware/hardware_account_data.dart';
|
||||
import 'package:cw_core/utils/print_verbose.dart';
|
||||
import 'package:cw_core/wallet_base.dart';
|
||||
import 'package:cw_core/wallet_credentials.dart';
|
||||
import 'package:cw_core/wallet_info.dart';
|
||||
@@ -82,7 +83,7 @@ abstract class WalletHardwareRestoreViewModelBase extends WalletCreationVM with
|
||||
// } on LedgerException catch (e) {
|
||||
// error = ledgerViewModel.interpretErrorCode(e.errorCode.toRadixString(16));
|
||||
} catch (e) {
|
||||
print(e);
|
||||
printV(e);
|
||||
error = S.current.ledger_connection_error;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user