mirror of https://github.com/stijndcl/didier
				
				
				
			Add command stats call to on_command
							parent
							
								
									97f6aa105d
								
							
						
					
					
						commit
						119d7c8dca
					
				|  | @ -4,6 +4,7 @@ import discord | ||||||
| from discord.ext import commands | from discord.ext import commands | ||||||
| from functions import checks, easterEggResponses | from functions import checks, easterEggResponses | ||||||
| from functions.database import stats, muttn, custom_commands | from functions.database import stats, muttn, custom_commands | ||||||
|  | from functions import commands as command_stats | ||||||
| import pytz | import pytz | ||||||
| import time | import time | ||||||
| import traceback | import traceback | ||||||
|  | @ -95,6 +96,7 @@ class Events(commands.Cog): | ||||||
|         print("{} in {}: {}".format(ctx.author.display_name, |         print("{} in {}: {}".format(ctx.author.display_name, | ||||||
|                                     "DM" if DM else "{} ({})".format(ctx.channel.name, ctx.guild.name), |                                     "DM" if DM else "{} ({})".format(ctx.channel.name, ctx.guild.name), | ||||||
|                                     ctx.message.content)) |                                     ctx.message.content)) | ||||||
|  |         command_stats.updateFile(ctx) | ||||||
| 
 | 
 | ||||||
|     @commands.Cog.listener() |     @commands.Cog.listener() | ||||||
|     async def on_command_error(self, ctx, err): |     async def on_command_error(self, ctx, err): | ||||||
|  |  | ||||||
|  | @ -0,0 +1,7 @@ | ||||||
|  | from discord.ext import commands | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | def updateFile(ctx: commands.Context): | ||||||
|  |     prefix_used = ctx.prefix | ||||||
|  |     command: commands.Command = ctx.command | ||||||
|  |     pass | ||||||
		Loading…
	
		Reference in New Issue