From ff6f39b71e72da825f6bac61eb3908386a519df6 Mon Sep 17 00:00:00 2001 From: tl-photography Date: Mon, 13 Jan 2025 21:31:49 +0100 Subject: [PATCH] [Shelly] apply further hardening against NPE Co-authored-by: Jacob Laursen Signed-off-by: tl-photography --- .../binding/shelly/internal/manager/ShellyManagerPage.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bundles/org.openhab.binding.shelly/src/main/java/org/openhab/binding/shelly/internal/manager/ShellyManagerPage.java b/bundles/org.openhab.binding.shelly/src/main/java/org/openhab/binding/shelly/internal/manager/ShellyManagerPage.java index a427489fdb8ce..9456211c3f529 100644 --- a/bundles/org.openhab.binding.shelly/src/main/java/org/openhab/binding/shelly/internal/manager/ShellyManagerPage.java +++ b/bundles/org.openhab.binding.shelly/src/main/java/org/openhab/binding/shelly/internal/manager/ShellyManagerPage.java @@ -413,7 +413,7 @@ protected FwRepoEntry getFirmwareRepoEntry(String deviceType, String mode) throw fw = fromJson(gson, entry, FwRepoEntry.class); // Special case: RGW2 has a split firmware - xxx-white.zip vs. xxx-color.zip - if (deviceType.equalsIgnoreCase(SHELLYDT_RGBW2) && !mode.isEmpty()) { + if (SHELLYDT_RGBW2.equalsIgnoreCase(deviceType) && !mode.isEmpty()) { // check for spilt firmware String url = substringBefore(fw.url, ".zip") + "-" + mode + ".zip"; if (testUrl(url)) {