From b015617e13472a38b1a827fcadf6264cb0615158 Mon Sep 17 00:00:00 2001 From: "j.delarago" Date: Wed, 1 Jun 2022 16:56:02 +0200 Subject: [PATCH] Marketplace plugin registry is None on initialization, and is loaded after running show(). This makes a check that the window is open before continuing through checkIfRestartNeeded CURA-6990 --- plugins/Marketplace/Marketplace.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/Marketplace/Marketplace.py b/plugins/Marketplace/Marketplace.py index 171e3f915b..e856245c3d 100644 --- a/plugins/Marketplace/Marketplace.py +++ b/plugins/Marketplace/Marketplace.py @@ -103,6 +103,9 @@ class Marketplace(Extension, QObject): self.setTabShown(1) def checkIfRestartNeeded(self) -> None: + if self._window is None: + return + if self._package_manager.hasPackagesToRemoveOrInstall or \ cast(PluginRegistry, self._plugin_registry).getCurrentSessionActivationChangedPlugins(): self._restart_needed = True