Skip to content

Commit 566171e

Browse files
authored
[shelly] fix NumberFormatException on Shelly2RelayStatus.timerDuration (openhab#17269)
- If 'Auto OFF' mode is enabled on a Shelly Plus 1 device and set to a value with decimal places a status update throws an NumberFormatException. Changed timerDuration/timer_duration from Integer to Double fixes the problem. Signed-off-by: Stefan Pledl <[email protected]>
1 parent 2080c85 commit 566171e

File tree

1 file changed

+1
-1
lines changed
  • bundles/org.openhab.binding.shelly/src/main/java/org/openhab/binding/shelly/internal/api2

1 file changed

+1
-1
lines changed

bundles/org.openhab.binding.shelly/src/main/java/org/openhab/binding/shelly/internal/api2/Shelly2ApiJsonDTO.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -865,7 +865,7 @@ public static class Shelly2RelayStatus {
865865
@SerializedName("timer_started_at")
866866
public Double timerStartetAt;
867867
@SerializedName("timer_duration")
868-
public Integer timerDuration;
868+
public Double timerDuration;
869869
public Double apower;
870870
public Double voltage;
871871
public Double current;

0 commit comments

Comments
 (0)