mirror of
https://github.com/esphome/esphome.git
synced 2024-11-26 17:05:21 +01:00
dashboard: Only ping when polling is active (#6001)
fixes https://github.com/esphome/issues/issues/5257
This commit is contained in:
parent
35388cf2a2
commit
0990d0812e
1 changed files with 1 additions and 0 deletions
|
@ -31,6 +31,7 @@ class PingStatus:
|
|||
while not dashboard.stop_event.is_set():
|
||||
# Only ping if the dashboard is open
|
||||
await dashboard.ping_request.wait()
|
||||
dashboard.ping_request.clear()
|
||||
current_entries = dashboard.entries.async_all()
|
||||
to_ping: list[DashboardEntry] = [
|
||||
entry for entry in current_entries if entry.address is not None
|
||||
|
|
Loading…
Reference in a new issue