fix getinfo, cleanup hash
This commit is contained in:
@@ -20,7 +20,7 @@ uint256 CBlockHeader::GetSHA256DHash() const
|
|||||||
|
|
||||||
uint256 CBlockHeader::GetVerusHash() const
|
uint256 CBlockHeader::GetVerusHash() const
|
||||||
{
|
{
|
||||||
if (hashPrevBlock == uint256())
|
if (hashPrevBlock.IsNull())
|
||||||
// always use SHA256D for genesis block
|
// always use SHA256D for genesis block
|
||||||
return SerializeHash(*this);
|
return SerializeHash(*this);
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -75,10 +75,7 @@ public:
|
|||||||
|
|
||||||
uint256 GetHash() const
|
uint256 GetHash() const
|
||||||
{
|
{
|
||||||
if (hashPrevBlock.IsNull())
|
return (this->*hashFunction)();
|
||||||
return (this->GetSHA256DHash());
|
|
||||||
else
|
|
||||||
return (this->*hashFunction)();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
uint256 GetSHA256DHash() const;
|
uint256 GetSHA256DHash() const;
|
||||||
|
|||||||
@@ -204,7 +204,7 @@ UniValue getinfo(const UniValue& params, bool fHelp)
|
|||||||
if ( ASSETCHAINS_STAKED != 0 )
|
if ( ASSETCHAINS_STAKED != 0 )
|
||||||
obj.push_back(Pair("staked", ASSETCHAINS_STAKED));
|
obj.push_back(Pair("staked", ASSETCHAINS_STAKED));
|
||||||
if ( ASSETCHAINS_LWMAPOS != 0 )
|
if ( ASSETCHAINS_LWMAPOS != 0 )
|
||||||
obj.push_back(Pair("verus proof of stake percent", ASSETCHAINS_LWMAPOS));
|
obj.push_back(Pair("veruspos", ASSETCHAINS_LWMAPOS));
|
||||||
}
|
}
|
||||||
return obj;
|
return obj;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user