mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 03:29:00 +08:00
Improved readability of putValue
This commit is contained in:
parent
3b4833a7e6
commit
c87bd83618
@ -169,7 +169,8 @@ class Script:
|
||||
# First add these parameters in order
|
||||
for parameter in ["G", "M", "T", "S", "F", "X", "Y", "Z", "E"]:
|
||||
if parameter in kwargs:
|
||||
line_parts.append(parameter + str(kwargs.pop(parameter)))
|
||||
value = kwargs.pop(parameter) # get the corresponding value and remove the parameter from kwargs
|
||||
line_parts.append(parameter + str(value))
|
||||
# Then add the rest of the parameters
|
||||
for parameter, value in kwargs.items():
|
||||
line_parts.append(parameter + str(value))
|
||||
|
Loading…
x
Reference in New Issue
Block a user