[core] Move comment to PROGMEM on ESP8266

This commit is contained in:
J. Nick Koston
2025-12-18 06:41:23 -10:00
parent 2cf6ed2af7
commit cd93468225
6 changed files with 88 additions and 22 deletions
+3 -1
View File
@@ -287,7 +287,9 @@ std::string WebServer::get_config_json() {
JsonObject root = builder.root();
root[ESPHOME_F("title")] = App.get_friendly_name().empty() ? App.get_name() : App.get_friendly_name();
root[ESPHOME_F("comment")] = App.get_comment_ref();
char comment_buffer[ESPHOME_COMMENT_SIZE];
App.get_comment_string(comment_buffer, sizeof(comment_buffer));
root[ESPHOME_F("comment")] = comment_buffer;
#if defined(USE_WEBSERVER_OTA_DISABLED) || !defined(USE_WEBSERVER_OTA)
root[ESPHOME_F("ota")] = false; // Note: USE_WEBSERVER_OTA_DISABLED only affects web_server, not captive_portal
#else