Closed Ghroom closed 1 year ago
Btw, I also added the fact that, if you are not an admin, I dont display the command in chat.
Maybe this is a hot-take, but I think we would only care about commands that are executed upon no? We have chat logs, but what would be easier to track and query are the commands that are executed and by whom.
In fact I think it would be easier to blow up DB rows if everyone who attempted a command got logged into a table. I'd rather have an easier table to query for the commands that are run, and leave the chat logs for all the failed attempts and typos (of which there will be many)
Added the basics of logging chat commands. enhancement must be done later. I also refactored some functions to check if it's an admin or if it's a command. (It was useless to check both when cheking if it's a chat command)
Pull request also present in the OPDB part for the creation of the log table.