forked from btclock/btclock_v3
Remove deprecated ArduinoJson methods
This commit is contained in:
parent
178748b94d
commit
0999dd08ad
3 changed files with 10 additions and 31 deletions
|
@ -127,7 +127,7 @@ namespace V2Notify
|
|||
|
||||
void handleV2Message(JsonDocument doc)
|
||||
{
|
||||
if (doc.containsKey("blockheight"))
|
||||
if (doc["blockheight"].is<JsonObject>())
|
||||
{
|
||||
uint newBlockHeight = doc["blockheight"].as<uint>();
|
||||
|
||||
|
@ -138,13 +138,13 @@ namespace V2Notify
|
|||
|
||||
processNewBlock(newBlockHeight);
|
||||
}
|
||||
else if (doc.containsKey("blockfee"))
|
||||
else if (doc["blockfee"].is<JsonObject>())
|
||||
{
|
||||
uint medianFee = doc["blockfee"].as<uint>();
|
||||
|
||||
processNewBlockFee(medianFee);
|
||||
}
|
||||
else if (doc.containsKey("price"))
|
||||
else if (doc["price"].is<JsonObject>())
|
||||
{
|
||||
|
||||
// Iterate through the key-value pairs of the "price" object
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue