diff --git a/src/packml-commands.js b/src/packml-commands.js index 528feaf..c605d45 100644 --- a/src/packml-commands.js +++ b/src/packml-commands.js @@ -25,7 +25,7 @@ exports.stateCommand = (logger, topic, message, state, stateCommandTopic) => { // handle mode commands exports.modeCommand = (logger, message, mode) => { if (isNaN(message)) { - message = message.toLowerCase() + message = message.toString().toLowerCase() } else { message = packmlModel.getModeTextByModeInt(message).toLowerCase() }