This commit is contained in:
Matthew Fosse 2024-08-14 13:16:52 -07:00
parent c4499869e5
commit 192045310c
2 changed files with 6 additions and 3 deletions

View file

@ -115,7 +115,10 @@ class ElectrumClient {
_setConnectionStatus(ConnectionStatus.failed);
}, onDone: () {
unterminatedString = '';
if (host == socket?.address.host) _setConnectionStatus(ConnectionStatus.disconnected);
if (host == socket?.address.host) {
_setConnectionStatus(ConnectionStatus.disconnected);
}
socket = null;
});
keepAlive();

View file

@ -222,10 +222,10 @@ abstract class LitecoinWalletBase extends ElectrumWallet with Store {
if (resp.blockHeaderHeight < nodeHeight) {
int h = resp.blockHeaderHeight;
syncStatus = SyncingSyncStatus(height - h, h / height);
syncStatus = SyncingSyncStatus(nodeHeight - h, h / nodeHeight);
} else if (resp.mwebHeaderHeight < nodeHeight) {
int h = resp.mwebHeaderHeight;
syncStatus = SyncingSyncStatus(height - h, h / height);
syncStatus = SyncingSyncStatus(nodeHeight - h, h / nodeHeight);
} else if (resp.mwebUtxosHeight < nodeHeight) {
syncStatus = SyncingSyncStatus(1, 0.999);
} else {