mirror of
https://github.com/esphome/esphome.git
synced 2026-09-03 19:46:02 +00:00
publish immediately on resume
This commit is contained in:
@@ -25,6 +25,9 @@ void SendspinTrackProgressSensor::setup() {
|
||||
this->stop_poller();
|
||||
this->publish_state(progress.track_progress);
|
||||
} else {
|
||||
// Resumed: publish the fresh interpolated position immediately so the frontend doesn't show a stale
|
||||
// paused value until the next poll tick.
|
||||
this->publish_state(this->parent_->get_track_progress_ms());
|
||||
this->start_poller();
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user