From 8ecc36436f06c7cd774a63ba3312564046febdba Mon Sep 17 00:00:00 2001 From: Cody Cutrer Date: Sun, 4 Aug 2024 14:10:33 -0600 Subject: [PATCH] [lutron] Fix Pico buttons for non-LEAP bridges (#17204) Signed-off-by: Cody Cutrer Signed-off-by: Ciprian Pascu --- .../binding/lutron/internal/handler/PicoKeypadHandler.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bundles/org.openhab.binding.lutron/src/main/java/org/openhab/binding/lutron/internal/handler/PicoKeypadHandler.java b/bundles/org.openhab.binding.lutron/src/main/java/org/openhab/binding/lutron/internal/handler/PicoKeypadHandler.java index 4f2cfd6bde6..c37e4ea8c59 100644 --- a/bundles/org.openhab.binding.lutron/src/main/java/org/openhab/binding/lutron/internal/handler/PicoKeypadHandler.java +++ b/bundles/org.openhab.binding.lutron/src/main/java/org/openhab/binding/lutron/internal/handler/PicoKeypadHandler.java @@ -69,7 +69,9 @@ public class PicoKeypadHandler extends BaseKeypadHandler { leapButtonMap = KeypadConfigPico.LEAPBUTTONS_3BRL; break; } - leapButtonInverseMap = leapButtonMap.entrySet().stream() - .collect(Collectors.toMap(Entry::getValue, Entry::getKey)); + if (getBridgeHandler() instanceof LeapBridgeHandler) { + leapButtonInverseMap = leapButtonMap.entrySet().stream() + .collect(Collectors.toMap(Entry::getValue, Entry::getKey)); + } } }