Fixed kill command not working in PM.

This commit is contained in:
ThePendulum 2022-09-24 17:52:13 +02:00
parent 09d344b394
commit bbe057eea2
2 changed files with 5 additions and 1 deletions

View File

@ -109,6 +109,7 @@ function onConnect(data, bot) {
}
function onRooms({ rooms, users }, bot) {
console.log('rooms', rooms);
logger.info(`Joined ${rooms.map((room) => room.name).join(', ')}`);
/* eslint-disable no-param-reassign */

View File

@ -1,8 +1,11 @@
const config = require('config');
function onCommand(args, context) {
console.log(context);
context.bot.socket.transmit('message', {
roomId: context.room.id,
roomId: context.room?.id,
recipient: context.message.user?.username,
body: 'Shutting down... :sleeping:',
style: config.style,
});