bed_mesh: Fix some fragile identity comparisons
Signed-off-by: Lucas Fink <software@lfcode.ca>
This commit is contained in:
parent
3da7697c66
commit
f6c2e8b4eb
|
@ -211,7 +211,7 @@ class BedMeshCalibrate:
|
||||||
stored_profs = config.get_prefix_sections(self.name)
|
stored_profs = config.get_prefix_sections(self.name)
|
||||||
# Remove primary bed_mesh section, as it is not a stored profile
|
# Remove primary bed_mesh section, as it is not a stored profile
|
||||||
stored_profs = [s for s in stored_profs
|
stored_profs = [s for s in stored_profs
|
||||||
if s.get_name() is not self.name]
|
if s.get_name() != self.name]
|
||||||
for profile in stored_profs:
|
for profile in stored_profs:
|
||||||
name = profile.get_name().split(' ', 1)[1]
|
name = profile.get_name().split(' ', 1)[1]
|
||||||
self.profiles[name] = {}
|
self.profiles[name] = {}
|
||||||
|
@ -292,7 +292,7 @@ class BedMeshCalibrate:
|
||||||
for key in options:
|
for key in options:
|
||||||
name = self.gcode.get_str(key, params, None)
|
name = self.gcode.get_str(key, params, None)
|
||||||
if name is not None:
|
if name is not None:
|
||||||
if name == "default" and key is not 'LOAD':
|
if name == "default" and key != 'LOAD':
|
||||||
self.gcode.respond_info(
|
self.gcode.respond_info(
|
||||||
"Profile 'default' is reserved, please chose"
|
"Profile 'default' is reserved, please chose"
|
||||||
" another profile name.")
|
" another profile name.")
|
||||||
|
|
Loading…
Reference in New Issue