Merged SChat and IRC support.
This commit is contained in:
@@ -22,7 +22,12 @@ function onCommand(args, context) {
|
||||
const room = Object.values(context.bot.rooms).find((botRoom) => botRoom.name === roomName);
|
||||
|
||||
if (room) {
|
||||
context.sendMessage(args.slice(1).join(' '), roomName, { label: false });
|
||||
context.sendMessage(args.slice(1).join(' '), room.id, { label: false });
|
||||
return;
|
||||
}
|
||||
|
||||
if (context.message.recipient === config.user.username) {
|
||||
context.sendMessage(args.join(' '), null, { type: 'message', label: false }, context.user.username);
|
||||
}
|
||||
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user