Use get instead of direct []

The next line (checking if the result is None) doesn't make sense otherwise

CURA-8463
This commit is contained in:
Jaime van Kessel 2022-08-30 13:13:32 +02:00
parent 587d71bb57
commit 143f796ba6
No known key found for this signature in database
GPG key ID: C85F7A3AF1BAA7C4

View file

@ -346,7 +346,7 @@ class CloudOutputDeviceManager:
output_device_manager.removeOutputDevice(device.key)
def _createMachineFromDiscoveredDevice(self, key: str, activate: bool = True) -> bool:
device = self._remote_clusters[key]
device = self._remote_clusters.get(key)
if not device:
return False