Commit f437d8e

benny-dou <60535774+benny-dou@users.noreply.github.com>
2025-12-09 23:52:57
fix(regex): exclude periods and commas in set_xx=yy pattern
1 parent 7b540ec
Changed files (1)
src/handler.py
@@ -376,7 +376,7 @@ def params_from_msg_text(texts: str | None = None) -> dict:
         params[match.lower()] = True
 
     # Pattern 3: #set_xx=var -> kwargs["xx"] = var
-    for match in re.findall(r"#set_(\w+)=([^,,.。#\s]+)", texts, re.IGNORECASE):  # noqa: RUF001
+    for match in re.findall(r"#set_(\w+)=([^,。#\s]+)", texts, re.IGNORECASE):  # noqa: RUF001
         key, value = match
         if str(value).lower() in ["none", "null"]:
             value = None