mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 14:37:29 -06:00
Abort importing profile if we have no global container stack
You shouldn't be able to trigger it anyway, but if you do, it'll give a proper error that the import failed. Contributes to issue CURA-2785.
This commit is contained in:
parent
06521d7c49
commit
d439015773
1 changed files with 2 additions and 0 deletions
|
@ -67,6 +67,8 @@ class LegacyProfileReader(ProfileReader):
|
|||
if file_name.split(".")[-1] != "ini":
|
||||
return None
|
||||
global_container_stack = Application.getInstance().getGlobalContainerStack()
|
||||
if not global_container_stack:
|
||||
return None
|
||||
|
||||
multi_extrusion = global_container_stack.getProperty("machine_extruder_count", "value") > 1
|
||||
if multi_extrusion:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue