From dce15cc8f3c1ae62ab30f1dfde92933c0b0a79b7 Mon Sep 17 00:00:00 2001 From: Laurent Garnier Date: Sat, 3 Sep 2022 11:44:45 +0200 Subject: [PATCH] [remoteopenhab] Handle REFRESH command as any command The received command (REFRESH) is transmitted as a REFRESH command to the remote item. Signed-off-by: Laurent Garnier --- .../internal/handler/RemoteopenhabBridgeHandler.java | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/bundles/org.openhab.binding.remoteopenhab/src/main/java/org/openhab/binding/remoteopenhab/internal/handler/RemoteopenhabBridgeHandler.java b/bundles/org.openhab.binding.remoteopenhab/src/main/java/org/openhab/binding/remoteopenhab/internal/handler/RemoteopenhabBridgeHandler.java index 57e46e3952142..8729f8f703243 100644 --- a/bundles/org.openhab.binding.remoteopenhab/src/main/java/org/openhab/binding/remoteopenhab/internal/handler/RemoteopenhabBridgeHandler.java +++ b/bundles/org.openhab.binding.remoteopenhab/src/main/java/org/openhab/binding/remoteopenhab/internal/handler/RemoteopenhabBridgeHandler.java @@ -75,7 +75,6 @@ import org.openhab.core.thing.type.ChannelTypeUID; import org.openhab.core.types.Command; import org.openhab.core.types.CommandOption; -import org.openhab.core.types.RefreshType; import org.openhab.core.types.State; import org.openhab.core.types.StateDescriptionFragmentBuilder; import org.openhab.core.types.StateOption; @@ -201,10 +200,7 @@ public void handleCommand(ChannelUID channelUID, Command command) { } try { - if (command instanceof RefreshType) { - String state = restClient.getRemoteItemState(channelUID.getId()); - updateChannelState(channelUID.getId(), null, state, false); - } else if (isLinked(channelUID)) { + if (isLinked(channelUID)) { restClient.sendCommandToRemoteItem(channelUID.getId(), command); String commandStr = command.toFullString(); logger.debug("Sending command {} to remote item {} succeeded",