Spaces:
Running
Running
Upload database.py
Browse files- akn/utils/database.py +9 -1
akn/utils/database.py
CHANGED
@@ -49,7 +49,9 @@ class Database:
|
|
49 |
self.gpt_4_bot = self.db_tiktok["gpt_4_bot"]
|
50 |
self.meta_bot = self.db_tiktok["metabot"]
|
51 |
self.youtube_bot = self.db_tiktok["youtubebot"]
|
52 |
-
|
|
|
|
|
53 |
# akeno
|
54 |
self.afk = self.db["afk"]
|
55 |
self.antiflood = self.db["antiflood"]
|
@@ -240,6 +242,12 @@ class Database:
|
|
240 |
async def get_all_youtube_bot(self) -> list:
|
241 |
return [i async for i in self.youtube_bot.find({})]
|
242 |
|
|
|
|
|
|
|
|
|
|
|
|
|
243 |
async def is_gbanned(self, user_id: int) -> bool:
|
244 |
if await self.gban.find_one({"user_id": user_id}):
|
245 |
return True
|
|
|
49 |
self.gpt_4_bot = self.db_tiktok["gpt_4_bot"]
|
50 |
self.meta_bot = self.db_tiktok["metabot"]
|
51 |
self.youtube_bot = self.db_tiktok["youtubebot"]
|
52 |
+
self.session_bot = self.db_tiktok["sessionbot"]
|
53 |
+
self.captcha_bot = self.db_tiktok["captchabot"]
|
54 |
+
|
55 |
# akeno
|
56 |
self.afk = self.db["afk"]
|
57 |
self.antiflood = self.db["antiflood"]
|
|
|
242 |
async def get_all_youtube_bot(self) -> list:
|
243 |
return [i async for i in self.youtube_bot.find({})]
|
244 |
|
245 |
+
async def get_all_session_bot(self) -> list:
|
246 |
+
return [i async for i in self.session_bot.find({})]
|
247 |
+
|
248 |
+
async def get_all_captcha_bot(self) -> list:
|
249 |
+
return [i async for i in self.captcha_bot.find({})]
|
250 |
+
|
251 |
async def is_gbanned(self, user_id: int) -> bool:
|
252 |
if await self.gban.find_one({"user_id": user_id}):
|
253 |
return True
|