mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 17:09:08 +08:00
Don't modify list you're iterating over
It doesn't give a problem right now since we're only iterating over lists of length 1 here, but in the future this could cause weird bugs. Contributes to issue CURA-2822.
This commit is contained in:
parent
8ae49c317c
commit
034686e9fa
@ -224,7 +224,7 @@ class ContainerManager(QObject):
|
||||
root = container.getMetaDataEntry(root_name)
|
||||
|
||||
item = root
|
||||
for entry in entries:
|
||||
for _ in range(len(entries)):
|
||||
item = item.get(entries.pop(0), { })
|
||||
|
||||
if item[entry_name] != entry_value:
|
||||
|
Loading…
x
Reference in New Issue
Block a user