[insteon] ignore commands if device is not online (#12787)
Signed-off-by: Rob Nielsen <rob.nielsen@yahoo.com>
This commit is contained in:
parent
6a6cf3e515
commit
5b79e18289
@ -410,9 +410,14 @@ public class InsteonDeviceHandler extends BaseThingHandler {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void handleCommand(ChannelUID channelUID, Command command) {
|
public void handleCommand(ChannelUID channelUID, Command command) {
|
||||||
logger.debug("channel {} was triggered with the command {}", channelUID.getAsString(), command);
|
if (ThingStatus.ONLINE.equals(getThing().getStatus())) {
|
||||||
|
logger.debug("channel {} was triggered with the command {}", channelUID.getAsString(), command);
|
||||||
|
|
||||||
getInsteonBinding().sendCommand(channelUID.getAsString(), command);
|
getInsteonBinding().sendCommand(channelUID.getAsString(), command);
|
||||||
|
} else {
|
||||||
|
logger.debug("the command {} for channel {} was ignored because the thing is not ONLINE", command,
|
||||||
|
channelUID.getAsString());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user