Skip to content

Commit

Permalink
Refactor CO2_Gadget_WIFI.h return two decimals for temperature and ze…
Browse files Browse the repository at this point in the history
…ro for humidity in getCO2GadgetStatusAsJson()
  • Loading branch information
melkati committed Jun 7, 2024
1 parent a9b3476 commit d0bfdaf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions CO2_Gadget_WIFI.h
Original file line number Diff line number Diff line change
Expand Up @@ -759,8 +759,8 @@ String getCO2GadgetStatusAsJson() {
StaticJsonDocument<512> doc;
doc["mainDeviceSelected"] = mainDeviceSelected;
doc["CO2"] = co2;
doc["Temperature"] = temp;
doc["Humidity"] = hum;
doc["Temperature"] = String(temp, 2);
doc["Humidity"] = String(hum, 0);
doc["WiFiStatus"] = WiFi.status();
doc["SSID"] = WiFi.SSID();
#ifndef WIFI_PRIVACY
Expand Down

0 comments on commit d0bfdaf

Please sign in to comment.