mirror of
				https://github.com/Rapptz/discord.py.git
				synced 2025-10-25 02:23:04 +00:00 
			
		
		
		
	[commands] Unload all cogs when gracefully exiting bot.
This commit is contained in:
		| @@ -274,6 +274,12 @@ class Bot(GroupMixin, discord.Client): | ||||
|             except: | ||||
|                 pass | ||||
|  | ||||
|         for cog in self.cogs: | ||||
|             try: | ||||
|                 self.remove_cog(cog) | ||||
|             except: | ||||
|                 pass | ||||
|  | ||||
|         yield from super().close() | ||||
|  | ||||
|     @asyncio.coroutine | ||||
|   | ||||
		Reference in New Issue
	
	Block a user