Ensure that check for updates is called on startup of Cura

CURA-8588
This commit is contained in:
Jaime van Kessel 2022-01-03 11:01:17 +01:00
parent 0615369cba
commit 3b2be48390
5 changed files with 42 additions and 19 deletions

View file

@ -132,9 +132,12 @@ class PackageList(ListModel):
:return: ``True`` if a Footer should be displayed in the ListView, e.q.: paginated lists, ``False`` Otherwise"""
return self._has_footer
def getPackageModel(self, package_id: str) -> PackageModel:
def getPackageModel(self, package_id: str) -> Optional[PackageModel]:
index = self.find("package", package_id)
return self.getItem(index)["package"]
data = self.getItem(index)
if data:
return data.get("package")
return None
def _openLicenseDialog(self, package_id: str, license_content: str) -> None:
plugin_path = self._plugin_registry.getPluginPath("Marketplace")