Skip to content

Commit

Permalink
Update uptime_connection_sensor.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
Lochnair authored Jul 17, 2024
1 parent b76b6f1 commit 406d446
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions components/cn105/uptime_connection_sensor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace esphome {
static const char* const TAG = "uptime.connection.sensor";
void HpUpTimeConnectionSensor::update() {
if (connected_) {
UptimeSensor::update();
UptimeSecondsSensor::update();
} else {
this->uptime_ = 0;
this->publish_state(0);
Expand All @@ -31,4 +31,4 @@ namespace esphome {
void HpUpTimeConnectionSensor::dump_config() { LOG_SENSOR("", "Uptime Connection Sensor", this); }

} // namespace uptime
} // namespace esphome
} // namespace esphome

0 comments on commit 406d446

Please sign in to comment.