Push on every refresh
This commit is contained in:
parent
8cd62b46ed
commit
900f476712
1 changed files with 6 additions and 7 deletions
13
wifi-mqtt.py
13
wifi-mqtt.py
|
@ -88,13 +88,12 @@ if __name__ == '__main__':
|
|||
continue
|
||||
|
||||
diff = activity.diff(prev_activity)
|
||||
if len(diff['joined']) > 0 or len(diff['parted']) > 0:
|
||||
hooks = [
|
||||
# hook_print,
|
||||
hook_mqtt,
|
||||
]
|
||||
for hook in hooks:
|
||||
hook(activity, prev_activity, diff)
|
||||
hooks = [
|
||||
# hook_print,
|
||||
hook_mqtt,
|
||||
]
|
||||
for hook in hooks:
|
||||
hook(activity, prev_activity, diff)
|
||||
|
||||
prev_activity = activity
|
||||
time.sleep(30)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue