Skip to content

Commit 2b2ebf2

Browse files
committed
Don't use overflowed -- was introduced in a later version of ArduinoJson
1 parent f73f224 commit 2b2ebf2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/MQTT/BulbStateUpdater.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ inline void BulbStateUpdater::flushGroup(BulbId bulbId, GroupState& state) {
4141
JsonObject message = json.to<JsonObject>();
4242
state.applyState(message, bulbId, settings.groupStateFields);
4343

44-
if (json.overflowed()) {
44+
if (json.memoryUsage() >= json.capacity()) {
4545
Serial.println(F("ERROR: State is too large for MQTT buffer, continuing anyway. Consider increasing MILIGHT_MQTT_JSON_BUFFER_SIZE."));
4646
}
4747

0 commit comments

Comments
 (0)