From c8594406420cb99632e993b2840215c3ceb580be Mon Sep 17 00:00:00 2001 From: Stefan Dej Date: Thu, 21 Mar 2024 18:27:52 +0100 Subject: [PATCH] fix: fix typo issues with save zoffset for probes (#1821) --- src/components/mixins/zoffset.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/components/mixins/zoffset.ts b/src/components/mixins/zoffset.ts index c4f8b63de..9785f34ca 100644 --- a/src/components/mixins/zoffset.ts +++ b/src/components/mixins/zoffset.ts @@ -32,14 +32,15 @@ export default class ZoffsetMixin extends Vue { get endstop_pin() { const stepperConfig = this.settings[this.stepper_name] ?? {} - return stepperConfig?.endstop_pin + return stepperConfig?.endstop_pin.trim() } get zOffset(): number { return this.$store.state.printer?.gcode_move?.homing_origin[2].toFixed(3) } get isEndstopProbe() { - return this.endstop_pin.search('probe:z_virtual_endstop') !== -1 + // remove spaces and search for probe:z_virtual_endstop + return this.endstop_pin.replaceAll(' ', '').search('probe:z_virtual_endstop') !== -1 } get existZOffsetApplyProbe() {