mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-14 06:25:59 +08:00
CuraContainerStack.py: improve TypeIndexMap
Cleaner and more idiomatic way to reverse a dictionary
This commit is contained in:
parent
2968f96e85
commit
60c8712b10
@ -427,4 +427,4 @@ class _ContainerIndexes:
|
|||||||
}
|
}
|
||||||
|
|
||||||
# Reverse lookup: type -> index
|
# Reverse lookup: type -> index
|
||||||
TypeIndexMap = dict([(v, k) for k, v in IndexTypeMap.items()])
|
TypeIndexMap = {v: k for k, v in IndexTypeMap.items()}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user