Simplify DateTimeType handling for Satel Integra Alarm System

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
This commit is contained in:
Jacob Laursen 2024-11-18 22:22:11 +01:00 committed by lsiepel
parent fb9a998f59
commit 751bbf7495

View File

@ -117,9 +117,9 @@ public class SatelSystemHandler extends SatelStateThingHandler {
dateTime = dateTimeCommand; dateTime = dateTimeCommand;
} }
if (dateTime != null) { if (dateTime != null) {
return Optional.of(new SetClockCommand(dateTime.getZonedDateTime() return Optional.of(
.withZoneSameInstant(bridgeHandler.getZoneId()).toLocalDateTime(), new SetClockCommand(dateTime.getZonedDateTime(bridgeHandler.getZoneId()).toLocalDateTime(),
bridgeHandler.getUserCode())); bridgeHandler.getUserCode()));
} }
break; break;
default: default: