mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-25 21:39:05 +01:00
rpc: return warnings as an array instead of just a single one
The RPC documentation for `getblockchaininfo`, `getmininginfo` and `getnetworkinfo` states that "warnings" returns "any network and blockchain warnings". In practice, only a single warning is returned. Fix that by returning all warnings as an array. As a side benefit, cleans up the GetWarnings() logic.
This commit is contained in:
@@ -513,4 +513,6 @@ private:
|
||||
void PushWarnings(const UniValue& warnings, UniValue& obj);
|
||||
void PushWarnings(const std::vector<bilingual_str>& warnings, UniValue& obj);
|
||||
|
||||
UniValue GetNodeWarnings(bool use_deprecated);
|
||||
|
||||
#endif // BITCOIN_RPC_UTIL_H
|
||||
|
||||
Reference in New Issue
Block a user