review fixes

This commit is contained in:
fosse 2024-01-25 11:04:31 -05:00
parent 884a53f607
commit 91b65e385b
2 changed files with 3 additions and 3 deletions

View file

@ -57,14 +57,14 @@ class WalletLoadingService {
raw: sharedPreferences.getInt(PreferencesKey.currentTorConnectionModeKey) ?? 0, raw: sharedPreferences.getInt(PreferencesKey.currentTorConnectionModeKey) ?? 0,
); );
if ([WalletType.bitcoin, WalletType.litecoin].contains(type)) { if ([WalletType.bitcoin, WalletType.litecoin, WalletType.bitcoinCash].contains(type)) {
bitcoin!.setTorOnly(wallet, mode == TorConnectionMode.torOnly); bitcoin!.setTorOnly(wallet, mode == TorConnectionMode.torOnly);
} }
final status = torViewModel.torConnectionStatus; final status = torViewModel.torConnectionStatus;
if (status == TorConnectionStatus.connected || status == TorConnectionStatus.connecting) { if (status == TorConnectionStatus.connected || status == TorConnectionStatus.connecting) {
// connect the node to the tor proxy: // connect the node to the tor proxy:
await torViewModel.startTor(); await torViewModel.connectOrDisconnectNodeToProxy(connect: true);
} }
return wallet; return wallet;

View file

@ -54,7 +54,7 @@ abstract class TorViewModelBase with Store {
} }
bool torOnly = _settingsStore.torConnectionMode == TorConnectionMode.torOnly; bool torOnly = _settingsStore.torConnectionMode == TorConnectionMode.torOnly;
if ([WalletType.bitcoin, WalletType.litecoin].contains(appStore.wallet!.type)) { if ([WalletType.bitcoin, WalletType.litecoin, WalletType.bitcoinCash].contains(appStore.wallet!.type)) {
bitcoin!.setTorOnly(appStore.wallet!, torOnly); bitcoin!.setTorOnly(appStore.wallet!, torOnly);
} }