From eafb2f28848245bf5bc424211699843ffccd7849 Mon Sep 17 00:00:00 2001 From: Sunn Yao Date: Mon, 14 Sep 2026 06:20:20 +0800 Subject: [PATCH] Change SearchStr to raw string for regex --- python/autojoin_on_invite.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/autojoin_on_invite.py b/python/autojoin_on_invite.py index fa85aa12..80b86f6a 100644 --- a/python/autojoin_on_invite.py +++ b/python/autojoin_on_invite.py @@ -92,7 +92,7 @@ def invite_cb(data, signal, signal_data): server = signal.split(',')[0] # EFNet,irc_in_INVITE channel = signal_data.split()[-1].lstrip(':') # :nick!ident@host.name INVITE yournick :#channel from_nick = '' - SearchStr = '(?:\@.*)?:(?P.+)!' #@time=2022-03-02T19:00:30.041Z :XX-XXXX!~XX-XXXX@xx.xxxx INVITE yournick :#xxxx-xxx (works also when no message-tag is present) + SearchStr = r'(?:\@.*)?:(?P.+)!' #@time=2022-03-02T19:00:30.041Z :XX-XXXX!~XX-XXXX@xx.xxxx INVITE yournick :#xxxx-xxx (works also when no message-tag is present) from_nick = re.search(SearchStr, signal_data).groups()[0] if len(w.config_get_plugin('whitelist_nicks')) > 0 and len(w.config_get_plugin('whitelist_channels')) > 0: # if there's two whitelists, accept both