1
0
mirror of https://github.com/esphome/esphome.git synced 2025-10-02 10:02:23 +01:00

update is a special case as well

This commit is contained in:
J. Nick Koston
2025-07-07 11:44:31 -05:00
parent 5de0f9efc9
commit 8ee86c717b

View File

@@ -357,7 +357,13 @@ void APIServer::on_event(event::Event *obj, const std::string &event_type) {
#endif #endif
#ifdef USE_UPDATE #ifdef USE_UPDATE
API_DISPATCH_UPDATE(update::UpdateEntity, update) // Update is a special case - the method is called on_update, not on_update_update
void APIServer::on_update(update::UpdateEntity *obj) {
if (obj->is_internal())
return;
for (auto &c : this->clients_)
c->send_update_state(obj);
}
#endif #endif
#ifdef USE_ALARM_CONTROL_PANEL #ifdef USE_ALARM_CONTROL_PANEL