tempstore initialization fixup

This commit is contained in:
alfrix 2023-08-15 18:05:04 -03:00 committed by Alfredo Monclus
parent adb150a2c7
commit 93bb6aeb65
2 changed files with 1 additions and 3 deletions

View File

@ -330,8 +330,6 @@ class Printer:
return True
def init_temp_store(self, tempstore):
if not tempstore:
logging.debug("Tempstore not ready")
if self.tempstore and list(self.tempstore) != list(tempstore):
logging.debug("Tempstore has changed")
self.tempstore = tempstore

View File

@ -904,7 +904,7 @@ class KlipperScreen(Gtk.Window):
def init_tempstore(self):
tempstore = self.apiclient.send_request("server/temperature_store")
if tempstore and 'result' in tempstore:
if tempstore and 'result' in tempstore and tempstore['result']:
self.printer.init_temp_store(tempstore['result'])
if hasattr(self.panels[self._cur_panels[-1]], "update_graph_visibility"):
self.panels[self._cur_panels[-1]].update_graph_visibility()