🐛 discovery: fix an exception during shutdown

This commit is contained in:
Gina Häußge committed 2020-08-05 11:51:50 +02:00
1 parent ad6230074a
commit abbbd926bc
1 file changed
+2 -1
+2 -1
View File
@@ -153,7 +153,8 @@ class DiscoveryPlugin(octoprint.plugin.StartupPlugin,
##~~ ShutdownPlugin API -- used for unregistering OctoPrint's Zeroconf and SSDP service upon application shutdown
def on_shutdown(self):
for key in self._zeroconf_registrations:
registrations = list(self._zeroconf_registrations.keys())
for key in registrations:
reg_type, port = key
self.zeroconf_unregister(reg_type, port)