Skip to content

Commit

Permalink
Adding default as a constant in AdminClientSettings
Browse files Browse the repository at this point in the history
  • Loading branch information
thdfw committed Jan 4, 2025
1 parent e232c55 commit b559c17
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gw_spaceheat/admin/watch/widgets/timer.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def reset(self) -> None:
input_value = self.app.query_one(TimeInput).value
try:
time_in_minutes = float(input_value) if input_value else int(self.default_timeout_seconds/60)
if input_value > int(AdminLinkSettings().max_timeout_seconds/60):
if time_in_minutes > int(AdminLinkSettings().max_timeout_seconds/60):
time_in_minutes = int(AdminLinkSettings().max_timeout_seconds/60)
except ValueError:
time_in_minutes = int(self.default_timeout_seconds/60)
Expand Down

0 comments on commit b559c17

Please sign in to comment.