MCPcopy Create free account
hub / github.com/TechifyBots/File-Stream-Bot / ban_user

Method ban_user

biisal/utils/database.py:48–54  ·  view source on GitHub ↗
(self , user_id)

Source from the content-addressed store, hash-verified

46 await self.col.delete_many({'id': int(user_id)})
47
48 async def ban_user(self , user_id):
49 user = await self.bannedList.find_one({'banId' : int(user_id)})
50 if user:
51 return False
52 else:
53 await self.bannedList.insert_one({'banId' : int(user_id)})
54 return True
55
56 async def is_banned(self , user_id):
57 user = await self.bannedList.find_one({'banId' : int(user_id)})

Callers 1

do_banFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected