Remove use of IsInitialBlockDownload in wallet code

This commit does not change behavior.
This commit is contained in:
Russell Yanofsky committed 2019-02-22 15:43:02 -04:00
1 parent 1106a6fde4
commit a1df1b48a8
3 files changed
+5 -1

No files matched your search

+1
View File
@@ -248,6 +248,7 @@ public:
CAmount maxTxFee() override { return ::maxTxFee; }
bool getPruneMode() override { return ::fPruneMode; }
bool p2pEnabled() override { return g_connman != nullptr; }
bool isInitialBlockDownload() override { return IsInitialBlockDownload(); }
int64_t getAdjustedTime() override { return GetAdjustedTime(); }
void initMessage(const std::string& message) override { ::uiInterface.InitMessage(message); }
void initWarning(const std::string& message) override { InitWarning(message); }
+3
View File
@@ -178,6 +178,9 @@ public:
//! Check if p2p enabled.
virtual bool p2pEnabled() = 0;
// Check if in IBD.
virtual bool isInitialBlockDownload() = 0;
//! Get adjusted time.
virtual int64_t getAdjustedTime() = 0;
+1 -1
View File
@@ -3889,7 +3889,7 @@ UniValue sethdseed(const JSONRPCRequest& request)
}.ToString());
}
if (IsInitialBlockDownload()) {
if (pwallet->chain().isInitialBlockDownload()) {
throw JSONRPCError(RPC_CLIENT_IN_INITIAL_DOWNLOAD, "Cannot set a new HD seed while still in Initial Block Download");
}