controller_fan: Replace else followed by single if with elif
Signed-off-by: Nils Friedchen <Nils.Friedchen@googlemail.com>
This commit is contained in:
parent
4e09cacece
commit
fd2f17f847
|
@ -44,8 +44,7 @@ class ControllerFan:
|
||||||
if active:
|
if active:
|
||||||
self.last_on = 0
|
self.last_on = 0
|
||||||
power = self.max_power
|
power = self.max_power
|
||||||
else:
|
elif self.last_on < self.idle_timeout:
|
||||||
if self.last_on < self.idle_timeout:
|
|
||||||
power = self.idle_speed
|
power = self.idle_speed
|
||||||
self.last_on += 1
|
self.last_on += 1
|
||||||
print_time = self.mcu.estimated_print_time(eventtime) + PIN_MIN_TIME
|
print_time = self.mcu.estimated_print_time(eventtime) + PIN_MIN_TIME
|
||||||
|
|
Loading…
Reference in New Issue