feat(command): 🎨 make botaddress prefix and regex more flexible and configurable
This commit is contained in:
+3
-1
@@ -86,7 +86,9 @@ reloadplugin = (event, filename, pluginpath) => {
|
||||
fs.watch('./lib/plugins', reloadplugin)
|
||||
|
||||
cfg.bot = bot
|
||||
cfg.botAddress = new RegExp(`^${bot.username} (!.+)`)
|
||||
// TODO better name, or switch to array
|
||||
cfg.botAddressPrefix = '!'
|
||||
cfg.botAddressRegex = new RegExp(`^${bot.username} (${cfg.botAddressPrefix}.+)`)
|
||||
cfg.quiet = true
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user