bugfix
This commit is contained in:
parent
1cbb44f714
commit
d00a13bb50
1 changed files with 1 additions and 1 deletions
|
|
@ -70,7 +70,7 @@ public class OnOffTrait extends DeviceTrait {
|
||||||
public void execute(HalAbstractDevice device, ExecuteRequest.Inputs.Payload.Commands.Execution execution) {
|
public void execute(HalAbstractDevice device, ExecuteRequest.Inputs.Payload.Commands.Execution execution) {
|
||||||
if ("action.devices.commands.OnOff".equals(execution.command)) {
|
if ("action.devices.commands.OnOff".equals(execution.command)) {
|
||||||
OnOffEventData eventData = new OnOffEventData();
|
OnOffEventData eventData = new OnOffEventData();
|
||||||
if ("on".equals(execution.getParams().get("on")))
|
if ((boolean) execution.getParams().get("on"))
|
||||||
eventData.turnOn();
|
eventData.turnOn();
|
||||||
else
|
else
|
||||||
eventData.turnOff();
|
eventData.turnOff();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue