From 2131ab26793316fde8dfde41e49b882f1a546d61 Mon Sep 17 00:00:00 2001 From: Alim Gokkaya Date: Sat, 30 Dec 2023 01:22:41 +0000 Subject: [PATCH] Upgrade to node 18 --- .github/workflows/cd.yaml | 2 +- src/command.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) 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 }