mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-04-15 02:31:57 +00:00
reversed investigative changes
This commit is contained in:
parent
176ed0f89f
commit
ae0631adeb
1 changed files with 4 additions and 28 deletions
|
@ -129,8 +129,6 @@ class XelisWallet extends LibXelisWallet {
|
|||
precomputedTablesPath: tablePath,
|
||||
l1Low: tableState.currentSize.isLow,
|
||||
);
|
||||
|
||||
print("Assigned wallet");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -192,33 +190,11 @@ class XelisWallet extends LibXelisWallet {
|
|||
|
||||
@override
|
||||
Future<bool> pingCheck() async {
|
||||
checkInitialized();
|
||||
try {
|
||||
final node = getCurrentNode();
|
||||
final daemon = xelis_sdk.DaemonClient(
|
||||
endPoint: "${node.host!}:${node.port!}",
|
||||
secureWebSocket: node.useSSL ?? false,
|
||||
timeout: 5000
|
||||
);
|
||||
daemon.connect();
|
||||
|
||||
final xelis_sdk.GetInfoResult networkInfo = await daemon.getInfo();
|
||||
bool testPassed = networkInfo.height != null;
|
||||
|
||||
daemon.disconnect();
|
||||
|
||||
if (testPassed) {
|
||||
GlobalEventBus.instance.fire(
|
||||
WalletSyncStatusChangedEvent(
|
||||
WalletSyncStatus.synced,
|
||||
walletId,
|
||||
info.coin,
|
||||
),
|
||||
);
|
||||
} else {
|
||||
await handleOffline();
|
||||
}
|
||||
|
||||
return testPassed;
|
||||
await libXelisWallet!.getDaemonInfo();
|
||||
await handleOnline();
|
||||
return true;
|
||||
} catch (_) {
|
||||
await handleOffline();
|
||||
return false;
|
||||
|
|
Loading…
Reference in a new issue