fan: Allow heater_fan to work with heater_bed

Fix order of init error preventing heater_fan from being used with
heater_bed.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2017-09-06 14:51:47 -04:00
parent 477b3941a6
commit 7d17002b33
3 changed files with 12 additions and 14 deletions

View file

@ -41,8 +41,6 @@ class PrinterHeaterFan:
self.fan = PrinterFan(printer, config)
heater = config.get("heater", "extruder0")
self.heater = extruder.get_printer_heater(printer, heater)
if self.heater is None:
raise config.error("Unknown heater '%s'" % (heater,))
self.heater_temp = config.getfloat("heater_temp", 50.0)
printer.reactor.register_timer(self.callback, printer.reactor.NOW)
def callback(self, eventtime):