aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/node.cpp
diff options
context:
space:
mode:
authorRussell Yanofsky <[email protected]>2020-05-29 00:07:18 -0400
committerRussell Yanofsky <[email protected]>2020-08-27 14:33:00 -0400
commitb266b3e0bf29d0f3d5deaeec62d57c5025b35525 (patch)
tree17843e21ddaedc1fbb82b86056b1fcbf8279bcef /src/interfaces/node.cpp
parentMerge bitcoin-core/gui#40: Clarify block height label (diff)
downloaddiscoin-b266b3e0bf29d0f3d5deaeec62d57c5025b35525.tar.xz
discoin-b266b3e0bf29d0f3d5deaeec62d57c5025b35525.zip
refactor: Create interfaces earlier during initialization
Add AppInitInterfaces function so wallet chain and chain client interfaces are created earlier during initialization. This is needed in the next commit to allow the gui splash screen to be able to register for wallet events through a dedicated WalletClient interface instead managing wallets indirectly through the Node interface. This only works if the wallet client interface is created before the splash screen needs to use it.
Diffstat (limited to 'src/interfaces/node.cpp')
-rw-r--r--src/interfaces/node.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/interfaces/node.cpp b/src/interfaces/node.cpp
index 206262eb0..73171686e 100644
--- a/src/interfaces/node.cpp
+++ b/src/interfaces/node.cpp
@@ -64,11 +64,10 @@ public:
bool baseInitialize() override
{
return AppInitBasicSetup(gArgs) && AppInitParameterInteraction(gArgs) && AppInitSanityChecks() &&
- AppInitLockDataDirectory();
+ AppInitLockDataDirectory() && AppInitInterfaces(*m_context);
}
bool appInitMain(interfaces::BlockAndHeaderTipInfo* tip_info) override
{
- m_context->chain = MakeChain(*m_context);
return AppInitMain(m_context_ref, *m_context, tip_info);
}
void appShutdown() override