Skip to content

Commit

Permalink
Correct routine
Browse files Browse the repository at this point in the history
  • Loading branch information
rgc99 committed Jun 26, 2024
1 parent 1aeb12b commit 2401f13
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/iu.ts
Original file line number Diff line number Diff line change
Expand Up @@ -186,9 +186,14 @@ export class IUSequence extends IUEntity {
zone.icon = z.icon;
zone.enabled = z.enabled;
zone.suspended = z.suspended ? new Date(z.suspended) : null;
zone.start = new Date(z.start);
zone._duration = hms_to_secs(z.duration);
zone.adjustment = z.adjustment;
zone.adjustment = z.adjustment;
if (z.start) {
zone.start = new Date(z.start);
zone._duration = hms_to_secs(z.duration);
} else {
zone.start = undefined;
zone._duration = 0;
}
if (zone.status === "off" && z.status === "on") {
zone._remaining = zone._duration;
zone.percent_completed = 0;
Expand Down

0 comments on commit 2401f13

Please sign in to comment.