mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-10 10:18:59 +08: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
@ -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…
x
Reference in New Issue
Block a user