Skip to content

Commit f605636

Browse files
committed
change regexp
1 parent 7be82d0 commit f605636

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cmdRepost/cmdRepost.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ def __init__(self, logger, core, config_file):
5656
self.timer = QTimer(self)
5757

5858
def check_tp(self, line):
59-
match_obj_1 = re.match(r'[^<>]*?\[Server thread/INFO\] \[minecraft/DedicatedServer\]: (.*)$', line)
59+
match_obj_1 = re.match(r'[^<>]*?\[Server thread/INFO\].*?: (.*)$', line)
6060
text = match_obj_1.group(1) if match_obj_1 else ''
6161
match_obj_2 = re.match(r'^Teleported (\w+)', text)
6262
if match_obj_2:
@@ -70,7 +70,7 @@ def check_tp(self, line):
7070
def check_repost(self, line):
7171
if self.repost_remained > 0:
7272
self.logger.debug('CmdReposter.repost_remained = {:d}'.format(self.repost_remained))
73-
match_obj_1 = re.match(r'[^<>]*?\[Server thread/INFO\] \[minecraft/DedicatedServer\]: ([^<>]*)$', line)
73+
match_obj_1 = re.match(r'[^<>]*?\[Server thread/INFO\].*?: ([^<>]*)$', line)
7474
if match_obj_1:
7575
self.utils.tell(self.repost_receiver, match_obj_1.group(1))
7676
self.repost_remained -= 1

0 commit comments

Comments
 (0)