mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 02:19:04 +08:00
Upgrade profile function now returns empty list if something went wrong.
Fixes CURA-1493
This commit is contained in:
parent
f81a5fe301
commit
c2341f7cd2
@ -54,10 +54,10 @@ class CuraProfileReader(ProfileReader):
|
|||||||
|
|
||||||
if not "general" in parser:
|
if not "general" in parser:
|
||||||
Logger.log("w", "Missing required section 'general'.")
|
Logger.log("w", "Missing required section 'general'.")
|
||||||
return None
|
return []
|
||||||
if not "version" in parser["general"]:
|
if not "version" in parser["general"]:
|
||||||
Logger.log("w", "Missing required 'version' property")
|
Logger.log("w", "Missing required 'version' property")
|
||||||
return None
|
return []
|
||||||
|
|
||||||
version = int(parser["general"]["version"])
|
version = int(parser["general"]["version"])
|
||||||
if InstanceContainer.Version != version:
|
if InstanceContainer.Version != version:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user