From 008a38aae2b043d92dea72f1daab804b1eb70373 Mon Sep 17 00:00:00 2001 From: rating89us <45968869+rating89us@users.noreply.github.com> Date: Fri, 10 Dec 2021 11:03:37 +0100 Subject: [PATCH] main: verify if currentWallet is loaded before calling it --- main.qml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/main.qml b/main.qml index af28f2c1..f856539a 100644 --- a/main.qml +++ b/main.qml @@ -730,14 +730,18 @@ ApplicationWindow { function onDaemonStarted(){ console.log("daemon started"); daemonStartStopInProgress = 0; - currentWallet.connected(true); - // resume refresh - currentWallet.startRefresh(); + if (currentWallet) { + currentWallet.connected(true); + // resume refresh + currentWallet.startRefresh(); + } // resume simplemode connection timer appWindow.disconnectedEpoch = Utils.epoch(); } function onDaemonStopped(){ - currentWallet.connected(true); + if (currentWallet) { + currentWallet.connected(true); + } } function onDaemonStartFailure(error) {