Spaces:
Sleeping
Sleeping
Captain Ezio
commited on
Commit
·
14dd820
1
Parent(s):
fb8e326
...
Browse files
Powers/plugins/clean_db.py
CHANGED
@@ -60,13 +60,14 @@ async def clean_my_db(c:Gojo,is_cmd=False, id=None):
|
|
60 |
x = len(to_clean)
|
61 |
txt = f"#INFO\n\nCleaned db:\nTotal chats removed: {x}"
|
62 |
to_clean.clear()
|
|
|
63 |
if is_cmd:
|
64 |
txt += f"\nClean type: Forced\nInitiated by: {(await c.get_users(user_ids=id)).mention}"
|
65 |
-
txt += f"\nClean type:
|
66 |
await c.send_message(chat_id=MESSAGE_DUMP,text=txt)
|
67 |
return txt
|
68 |
else:
|
69 |
-
txt += f"\nClean type: Auto\n\tTook {
|
70 |
await c.send_message(chat_id=MESSAGE_DUMP,text=txt)
|
71 |
return txt
|
72 |
|
|
|
60 |
x = len(to_clean)
|
61 |
txt = f"#INFO\n\nCleaned db:\nTotal chats removed: {x}"
|
62 |
to_clean.clear()
|
63 |
+
nums = time.time()-start
|
64 |
if is_cmd:
|
65 |
txt += f"\nClean type: Forced\nInitiated by: {(await c.get_users(user_ids=id)).mention}"
|
66 |
+
txt += f"\nClean type: Manual\n\tTook {round(nums,2)} seconds to complete the process"
|
67 |
await c.send_message(chat_id=MESSAGE_DUMP,text=txt)
|
68 |
return txt
|
69 |
else:
|
70 |
+
txt += f"\nClean type: Auto\n\tTook {round(nums,2)} seconds to complete the process"
|
71 |
await c.send_message(chat_id=MESSAGE_DUMP,text=txt)
|
72 |
return txt
|
73 |
|