正则匹配时加入多行匹配
发来的消息带回车时,使用dotall一直匹配下去 Signed-off-by: lcroof <lcroof@qq.com>
This commit is contained in:
parent
ca46134b81
commit
d839e57a3c
|
@ -250,8 +250,8 @@ class PluginsLoader {
|
|||
if (plugin.rule) for (const v of plugin.rule) {
|
||||
/** 判断事件 */
|
||||
if (v.event && !this.filtEvent(e, v)) continue
|
||||
|
||||
if (!new RegExp(v.reg).test(e.msg)) continue
|
||||
/** 加入多行匹配符号 */
|
||||
if (!new RegExp(v.reg, 'sg').test(e.msg)) continue
|
||||
e.logFnc = `[${plugin.name}][${v.fnc}]`
|
||||
|
||||
if (v.log !== false)
|
||||
|
|
Loading…
Reference in New Issue