bundles/infobeamer-monitor: improve code a bit
This commit is contained in:
parent
b5475df467
commit
9be370f8df
1 changed files with 2 additions and 0 deletions
|
@ -117,6 +117,7 @@ while True:
|
|||
LOG.info("device {} is now {}".format(did, online_status))
|
||||
mqtt_out(
|
||||
f"online status changed to {online_status}",
|
||||
level="INFO" if device["is_online"] else "WARN",
|
||||
device=device,
|
||||
)
|
||||
if device["is_online"]:
|
||||
|
@ -131,6 +132,7 @@ while True:
|
|||
level="WARN",
|
||||
device=device,
|
||||
)
|
||||
must_dump_state = True
|
||||
|
||||
if (
|
||||
device["is_synced"] != state[did]["is_synced"]
|
||||
|
|
Loading…
Reference in a new issue