diff --git a/.github/workflows/cd.yaml b/.github/workflows/cd.yaml index b02f5c7..d4b667b 100644 --- a/.github/workflows/cd.yaml +++ b/.github/workflows/cd.yaml @@ -11,7 +11,7 @@ jobs: strategy: matrix: - node-version: [16.x] + node-version: [18.x] steps: - uses: actions/checkout@v2 diff --git a/src/command.ts b/src/command.ts index 4ee66e6..7c01867 100644 --- a/src/command.ts +++ b/src/command.ts @@ -98,7 +98,7 @@ export function makeCommander(botContext: BotContext) { .split(/ +/); for (const [keywords, command] of Object.entries(botCommands)) { const kw = keywords.split(" ") - if (words.slice(0, kw.length) === kw) { + if (words.slice(0, kw.length).join(" ") === kw.join(" ")) { await command(message, words) return }