Skip to content

Commit dbdc1c7

Browse files
committed
philips-hue: Refresh device on online sse update
1 parent d51954b commit dbdc1c7

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

drivers/SmartThings/philips-hue/src/handlers/attribute_emitters.lua

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,11 @@ function AttributeEmitters.connectivity_update(child_device, zigbee_status)
175175
child_device.log.info_with({hub_logs=true}, "Device zigbee status event, marking device online")
176176
child_device:online()
177177
child_device:set_field(Fields.IS_ONLINE, true)
178+
child_device.driver:inject_capability_command(child_device, {
179+
capability = capabilities.refresh.ID,
180+
command = capabilities.refresh.commands.refresh.NAME,
181+
args = {}
182+
})
178183
elseif zigbee_status.status == "connectivity_issue" then
179184
child_device.log.info_with({hub_logs=true}, "Device zigbee status event, marking device offline")
180185
child_device:set_field(Fields.IS_ONLINE, false)

0 commit comments

Comments
 (0)