configurable prefix

This commit is contained in:
hgw 2023-10-02 02:11:25 +00:00
parent 6727a1268d
commit 624934c902
2 changed files with 7 additions and 4 deletions

8
bot.js
View File

@ -79,12 +79,14 @@ async function twitter(chan, provfeed, n) {
bot.addListener('message', function(nick, to, text, from) {
var args = text.split(' ');
if (args[0] === 'm!help') {
if (args[0] === config.irc.prefix+'help') {
help(to, args[1]);
} else if (args[0] === 'm!feed') {
} else if (args[0] === config.irc.prefix+'feed') {
feed(to, args[1], args[2]);
} else if (args[0] === 'm!twitter') {
} else if (args[0] === config.irc.prefix+'twitter') {
twitter(to, args[1], args[2])
} else if (args[0] === config.irc.prefix+'set') {
}
});

View File

@ -11,7 +11,8 @@
"realname": "git.supernets.org/hogwart7/mercury",
"autorejoin": "true",
"floodprotection": "false",
"floodprotectiondelay": "0"
"floodprotectiondelay": "0",
"prefix": "m!"
},
"colours": {
"date": "11",