clean up unused lines, comments, and output strings

This commit is contained in:
Nayan
2025-08-27 01:21:33 +00:00
parent 329d914211
commit 45e941bac3
2 changed files with 16 additions and 35 deletions

View File

@@ -3,11 +3,10 @@ import re
import random
async def processline(line, regex_list, fprint_list, bot_instance, channel):
''' Process a line of output from the server and send it to Discord if it matches a regex. '''
for i in range(len(regex_list)):
# print(f"Processing line: {line}")
match = regex_list[i].match(line)
if match:
# print(f"Matched line: {line}")
groups = match.groups()
discord_message = fprint_list[i].format(groups=groups)
# Limit message length for Discord if necessary
@@ -17,8 +16,7 @@ async def processline(line, regex_list, fprint_list, bot_instance, channel):
await bot_instance.loop.create_task(channel.send(discord_message))
# else:
# # Optionally, you can log other server output to a debug channel or console
# if random.random() < 0.01:
# print(f"Non-chat output: {line}")
def testreload():
return "some new string"
return "reloaded successfully"