This commit is contained in:
2024-04-09 19:21:06 +02:00
parent 0584df9143
commit 95785199c0
+3 -2
View File
@@ -58,12 +58,13 @@ Music_Config = TypedDict(
class QueryControl:
def __init__(self, query_author, query_uuid, query_content, uplogger) -> None:
def __init__(self, query_author, query_uuid, query_content, uplogger, ctx) -> None:
self.author = query_author
self.uuid = query_uuid
self.content = query_content
self.logger = uplogger
self.stop = False
self.ctx = ctx
self.logger.info(
f"Created Query control for {self.author}, {self.uuid}: {self.content}"
)
@@ -2139,7 +2140,7 @@ async def wyszukaj_linki_do_dokumentow(ctx):
username = ctx.message.author.nick
else:
username = ctx.message.author.name
query_object = QueryControl(username, query_uuid, query, logger)
query_object = QueryControl(username, query_uuid, query, logger, ctx)
OUT_COMM_Q.put(query_object)
await ctx.send(f"No dobra poszło. Zapamiętaj proszę {query_uuid} - to identyfikator twojego zapytania. Jesteś {queue_size} w kolejce."+
" Zapytania obsługuje algorytm zasilany czterema chomikami zapierdalającymi w kołowrotku - więc wyniki najwcześniej za kilka godzi - ale mogą być też dni.")