Added say command with operator config.

This commit is contained in:
2021-11-15 20:44:34 +01:00
parent 2ddac57365
commit 18ffdefffb
3 changed files with 27 additions and 3 deletions
+2 -2
View File
@@ -209,10 +209,10 @@ function getGames(bot) {
const games = config.games.reduce((acc, key) => {
const game = require(`./games/${key.game || key}`); // eslint-disable-line global-require, import/no-dynamic-require
const sendMessage = (body, roomId) => {
const sendMessage = (body, roomId, options) => {
bot.socket.transmit('message', {
roomId,
body: `[${game.name || key}] ${body}`,
body: options?.label === false ? body : `[${game.name || key}] ${body}`,
style: config.style,
});
};