DVCSMP-1505 LIFX setColor() throws exception

-Added empty return to command methods since sendEvent is used
-Added null check for hex values
This commit is contained in:
Lars Finander
2016-02-22 15:11:56 -08:00
parent a4ebe87f4e
commit 42b790ef10
2 changed files with 13 additions and 1 deletions

View File

@@ -84,6 +84,7 @@ def setLevel(percentage) {
log.error("Bad setLevel result: [${resp.status}] ${resp.data}")
}
}
return []
}
def setColorTemperature(kelvin) {
@@ -99,6 +100,7 @@ def setColorTemperature(kelvin) {
log.error("Bad setColorTemperature result: [${resp.status}] ${resp.data}")
}
}
return []
}
def on() {
@@ -108,6 +110,7 @@ def on() {
sendEvent(name: "switch", value: "on")
}
}
return []
}
def off() {
@@ -117,6 +120,7 @@ def off() {
sendEvent(name: "switch", value: "off")
}
}
return []
}
def poll() {