[core] Move device class strings to PROGMEM on ESP8266 (#14443)

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
J. Nick Koston
2026-03-06 08:34:27 -10:00
committed by GitHub
co-authored by Copilot
parent b2378e830e
commit 8a915dcbbe
17 changed files with 167 additions and 108 deletions
+2 -1
View File
@@ -2137,7 +2137,8 @@ json::SerializationBuffer<> WebServer::event_json_(event::Event *obj, StringRef
for (const char *event_type : obj->get_event_types()) {
event_types.add(event_type);
}
root[ESPHOME_F("device_class")] = obj->get_device_class_ref();
char dc_buf[MAX_DEVICE_CLASS_LENGTH];
root[ESPHOME_F("device_class")] = obj->get_device_class_to(dc_buf);
this->add_sorting_info_(root, obj);
}