mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-07 06:57:28 -06:00
Initialise config_name
Just a mistake that I saw because my IDE warned me about this. If a variant in Cura 2.3 has no general/name keyword, then it would break here. Now it doesn't break any more and gives a nonsensical name. Contributes to issue CURA-3427.
This commit is contained in:
parent
0a84a181c4
commit
6e01c6ba60
1 changed files with 1 additions and 0 deletions
|
@ -77,6 +77,7 @@ class VersionUpgrade22to24(VersionUpgrade):
|
|||
with open(variant_path, "r") as fhandle:
|
||||
variant_config.read_file(fhandle)
|
||||
|
||||
config_name = "Unknown Variant"
|
||||
if variant_config.has_section("general") and variant_config.has_option("general", "name"):
|
||||
config_name = variant_config.get("general", "name")
|
||||
if config_name.endswith("_variant"):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue