mirror of
https://github.com/moltbot/moltbot.git
synced 2026-03-21 16:41:56 +00:00
docs(auto-reply): align silent token comment with regex
This commit is contained in:
@@ -11,8 +11,8 @@ export function isSilentReplyText(
|
||||
return false;
|
||||
}
|
||||
const escaped = escapeRegExp(token);
|
||||
// Only match when the entire response (trimmed) is the silent token,
|
||||
// optionally surrounded by whitespace. This prevents
|
||||
// Match only the exact silent token with optional surrounding whitespace.
|
||||
// This prevents
|
||||
// substantive replies ending with NO_REPLY from being suppressed (#19537).
|
||||
return new RegExp(`^\\s*${escaped}\\s*$`).test(text);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user