From 701dd0ac8c5e33a01a454dcbe5938719c754f8fe Mon Sep 17 00:00:00 2001 From: kwaroran Date: Thu, 7 Mar 2024 23:28:54 +0900 Subject: [PATCH] Add null check in smMatcher function --- src/ts/parser.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/ts/parser.ts b/src/ts/parser.ts index 946abd1a..17f7935c 100644 --- a/src/ts/parser.ts +++ b/src/ts/parser.ts @@ -737,6 +737,9 @@ const matcher = (p1:string,matcherArg:matcherArg) => { } const smMatcher = (p1:string,matcherArg:matcherArg) => { + if(!p1){ + return null + } const lowerCased = p1.toLocaleLowerCase() const db = matcherArg.db const chara = matcherArg.chara