Add listeners at init

Remove duplicated listener registration

Signed-off-by: HenrikJannsen <boilingfrog@gmx.com>
This commit is contained in:
HenrikJannsen 2023-01-05 22:02:57 -05:00 committed by Alejandro García
parent 509b07d7dc
commit a6208f10dd
No known key found for this signature in database
GPG key ID: F806F422E222AA02

View file

@ -69,9 +69,6 @@ public class DaoPresentation implements DaoStateListener, DaoStateMonitoringServ
}
});
daoStateService.addDaoStateListener(this);
daoStateMonitoringService.addListener(this);
walletChainHeightListener = (observable, oldValue, newValue) -> onUpdateAnyChainHeight();
}
@ -84,6 +81,7 @@ public class DaoPresentation implements DaoStateListener, DaoStateMonitoringServ
btcWalletService.getChainHeightProperty().addListener(walletChainHeightListener);
daoStateService.addDaoStateListener(this);
daoStateMonitoringService.addListener(this);
onUpdateAnyChainHeight();
}