From c6087e6b00a26c29a95dbd875187b670359db32b Mon Sep 17 00:00:00 2001 From: Jacob Laursen Date: Sun, 17 Nov 2024 18:27:32 +0100 Subject: [PATCH] Simplify DateTimeType handling for KM200 Signed-off-by: Jacob Laursen --- .../binding/km200/internal/handler/KM200DataHandler.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bundles/org.openhab.binding.km200/src/main/java/org/openhab/binding/km200/internal/handler/KM200DataHandler.java b/bundles/org.openhab.binding.km200/src/main/java/org/openhab/binding/km200/internal/handler/KM200DataHandler.java index e733bf4bf34..5afc79f6b18 100644 --- a/bundles/org.openhab.binding.km200/src/main/java/org/openhab/binding/km200/internal/handler/KM200DataHandler.java +++ b/bundles/org.openhab.binding.km200/src/main/java/org/openhab/binding/km200/internal/handler/KM200DataHandler.java @@ -16,6 +16,7 @@ import static org.openhab.binding.km200.internal.KM200BindingConstants.*; import java.math.BigDecimal; import java.math.RoundingMode; +import java.time.ZoneId; import java.time.ZonedDateTime; import java.util.HashMap; import java.util.List; @@ -675,7 +676,7 @@ public class KM200DataHandler { break; } } else if (CoreItemFactory.DATETIME.equals(itemType)) { - ZonedDateTime swTime = ((DateTimeType) command).getZonedDateTime(); + ZonedDateTime swTime = ((DateTimeType) command).getZonedDateTime(ZoneId.systemDefault()); KM200SwitchProgramServiceHandler sPService = ((KM200SwitchProgramServiceHandler) objParent .getValueParameter()); if (null != sPService) {