Make activeMachineIsGroup more robust

This commit is contained in:
ChrisTerBeke 2019-01-11 16:08:46 +01:00
parent b78ac0664f
commit 36e49ee6bb

View file

@ -534,7 +534,7 @@ class MachineManager(QObject):
@pyqtProperty(bool, notify = printerConnectedStatusChanged) @pyqtProperty(bool, notify = printerConnectedStatusChanged)
def activeMachineIsGroup(self) -> bool: def activeMachineIsGroup(self) -> bool:
return bool(self._printer_output_devices) and self._printer_output_devices[0].clusterSize > 1 return bool(self._printer_output_devices) and len(self._printer_output_devices[0].printers) > 1
@pyqtProperty(bool, notify = printerConnectedStatusChanged) @pyqtProperty(bool, notify = printerConnectedStatusChanged)
def activeMachineHasActiveNetworkConnection(self) -> bool: def activeMachineHasActiveNetworkConnection(self) -> bool: