Skip to content

Commit

Permalink
refactor: also allow FILAMENT_LOAD and FILAMENT_UNLOAD macros (#1639)
Browse files Browse the repository at this point in the history
  • Loading branch information
meteyou authored Nov 3, 2023
1 parent 049997a commit af547b3
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/components/panels/ExtruderControlPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,15 @@ export default class ExtruderControlPanel extends Mixins(BaseMixin, ControlMixin
}
get loadFilamentMacro(): PrinterStateMacro | undefined {
return this.macros.find((macro: PrinterStateMacro) => macro.name.toUpperCase() === 'LOAD_FILAMENT')
const macros = ['LOAD_FILAMENT', 'FILAMENT_LOAD']
return this.macros.find((macro: PrinterStateMacro) => macros.includes(macro.name.toUpperCase()))
}
get unloadFilamentMacro(): PrinterStateMacro | undefined {
return this.macros.find((macro: PrinterStateMacro) => macro.name.toUpperCase() === 'UNLOAD_FILAMENT')
const macros = ['UNLOAD_FILAMENT', 'FILAMENT_UNLOAD']
return this.macros.find((macro: PrinterStateMacro) => macros.includes(macro.name.toUpperCase()))
}
/**
Expand Down

0 comments on commit af547b3

Please sign in to comment.