Get rid of Params().RPCisTestNet()
This commit is contained in:
parent
e164828105
commit
b82b7ec3dc
4 changed files with 2 additions and 8 deletions
|
@ -178,7 +178,6 @@ public:
|
||||||
fDefaultCheckMemPool = false;
|
fDefaultCheckMemPool = false;
|
||||||
fAllowMinDifficultyBlocks = false;
|
fAllowMinDifficultyBlocks = false;
|
||||||
fRequireStandard = true;
|
fRequireStandard = true;
|
||||||
fRPCisTestNet = false;
|
|
||||||
fMineBlocksOnDemand = false;
|
fMineBlocksOnDemand = false;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -230,7 +229,6 @@ public:
|
||||||
fDefaultCheckMemPool = false;
|
fDefaultCheckMemPool = false;
|
||||||
fAllowMinDifficultyBlocks = true;
|
fAllowMinDifficultyBlocks = true;
|
||||||
fRequireStandard = false;
|
fRequireStandard = false;
|
||||||
fRPCisTestNet = true;
|
|
||||||
fMineBlocksOnDemand = false;
|
fMineBlocksOnDemand = false;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -269,7 +267,6 @@ public:
|
||||||
fDefaultCheckMemPool = true;
|
fDefaultCheckMemPool = true;
|
||||||
fAllowMinDifficultyBlocks = true;
|
fAllowMinDifficultyBlocks = true;
|
||||||
fRequireStandard = false;
|
fRequireStandard = false;
|
||||||
fRPCisTestNet = true;
|
|
||||||
fMineBlocksOnDemand = true;
|
fMineBlocksOnDemand = true;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -70,8 +70,6 @@ public:
|
||||||
bool AllowMinDifficultyBlocks() const { return fAllowMinDifficultyBlocks; }
|
bool AllowMinDifficultyBlocks() const { return fAllowMinDifficultyBlocks; }
|
||||||
/* Make standard checks */
|
/* Make standard checks */
|
||||||
bool RequireStandard() const { return fRequireStandard; }
|
bool RequireStandard() const { return fRequireStandard; }
|
||||||
/* Make standard checks */
|
|
||||||
bool RPCisTestNet() const { return fRPCisTestNet; }
|
|
||||||
const std::string& DataDir() const { return strDataDir; }
|
const std::string& DataDir() const { return strDataDir; }
|
||||||
/* Make miner stop after a block is found. In RPC, don't return
|
/* Make miner stop after a block is found. In RPC, don't return
|
||||||
* until nGenProcLimit blocks are generated */
|
* until nGenProcLimit blocks are generated */
|
||||||
|
@ -110,7 +108,6 @@ protected:
|
||||||
bool fDefaultCheckMemPool;
|
bool fDefaultCheckMemPool;
|
||||||
bool fAllowMinDifficultyBlocks;
|
bool fAllowMinDifficultyBlocks;
|
||||||
bool fRequireStandard;
|
bool fRequireStandard;
|
||||||
bool fRPCisTestNet;
|
|
||||||
bool fMineBlocksOnDemand;
|
bool fMineBlocksOnDemand;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -268,7 +268,7 @@ Value getmininginfo(const Array& params, bool fHelp)
|
||||||
obj.push_back(Pair("genproclimit", (int)GetArg("-genproclimit", -1)));
|
obj.push_back(Pair("genproclimit", (int)GetArg("-genproclimit", -1)));
|
||||||
obj.push_back(Pair("networkhashps", getnetworkhashps(params, false)));
|
obj.push_back(Pair("networkhashps", getnetworkhashps(params, false)));
|
||||||
obj.push_back(Pair("pooledtx", (uint64_t)mempool.size()));
|
obj.push_back(Pair("pooledtx", (uint64_t)mempool.size()));
|
||||||
obj.push_back(Pair("testnet", Params().RPCisTestNet()));
|
obj.push_back(Pair("testnet", Params().NetworkID() == CChainParams::TESTNET));
|
||||||
#ifdef ENABLE_WALLET
|
#ifdef ENABLE_WALLET
|
||||||
obj.push_back(Pair("generate", getgenerate(params, false)));
|
obj.push_back(Pair("generate", getgenerate(params, false)));
|
||||||
obj.push_back(Pair("hashespersec", gethashespersec(params, false)));
|
obj.push_back(Pair("hashespersec", gethashespersec(params, false)));
|
||||||
|
|
|
@ -73,7 +73,7 @@ Value getinfo(const Array& params, bool fHelp)
|
||||||
obj.push_back(Pair("connections", (int)vNodes.size()));
|
obj.push_back(Pair("connections", (int)vNodes.size()));
|
||||||
obj.push_back(Pair("proxy", (proxy.first.IsValid() ? proxy.first.ToStringIPPort() : string())));
|
obj.push_back(Pair("proxy", (proxy.first.IsValid() ? proxy.first.ToStringIPPort() : string())));
|
||||||
obj.push_back(Pair("difficulty", (double)GetDifficulty()));
|
obj.push_back(Pair("difficulty", (double)GetDifficulty()));
|
||||||
obj.push_back(Pair("testnet", Params().RPCisTestNet()));
|
obj.push_back(Pair("testnet", Params().NetworkID() == CChainParams::TESTNET));
|
||||||
#ifdef ENABLE_WALLET
|
#ifdef ENABLE_WALLET
|
||||||
if (pwalletMain) {
|
if (pwalletMain) {
|
||||||
obj.push_back(Pair("keypoololdest", pwalletMain->GetOldestKeyPoolTime()));
|
obj.push_back(Pair("keypoololdest", pwalletMain->GetOldestKeyPoolTime()));
|
||||||
|
|
Loading…
Reference in a new issue