Implemented custom per-channel !toke commands in back-end.

This commit is contained in:
rainbow napkin 2024-12-15 09:51:32 -05:00
parent 575244ac53
commit a1fbbea7b7
10 changed files with 159 additions and 29 deletions

View file

@ -45,7 +45,7 @@ tokeCommandSchema.pre('save', async function (next){
});
tokeCommandSchema.pre('deleteOne', {document: true}, async function (next){
//Get server tokebot object
//Get server tokebot object (isn't this a fun dot crawler? Why hasn't anyone asked me to stop writing software yet?)
const tokebot = server.channelManager.chatHandler.commandPreprocessor.tokebot;
//Get the index of the command within tokeCommand and splice it out