Merge branch 'CURA-7458_Add_offline_cloud_printers_in_Cura' of github.com:Ultimaker/Cura

This commit is contained in:
Jaime van Kessel 2020-06-02 10:55:21 +02:00
commit f1d3c2272e
No known key found for this signature in database
GPG Key ID: 3710727397403C91

View File

@ -98,9 +98,10 @@ class CloudOutputDeviceManager:
"""Callback for when the request for getting the clusters is finished."""
new_clusters = []
all_clusters = {c.cluster_id: c for c in clusters} # type: Dict[str, CloudClusterResponse]
online_clusters = {c.cluster_id: c for c in clusters if c.is_online} # type: Dict[str, CloudClusterResponse]
for device_id, cluster_data in online_clusters.items():
for device_id, cluster_data in all_clusters.items():
if device_id not in self._remote_clusters:
new_clusters.append(cluster_data)