This commit is contained in:
Flummi 2018-03-16 16:23:01 +01:00
parent b62a4c081c
commit af3f00a704

View File

@ -76,7 +76,10 @@ export class irc extends EventEmitter {
logger.debug(`(${this.network}) out: ${data}`); logger.debug(`(${this.network}) out: ${data}`);
} }
sendmsg(mode, recipient, msg) { sendmsg(mode, recipient, msg) {
msg.split(/\r?\n/).forEach(e => { msg = msg.split(/\r?\n/);
if(msg.length > 6)
return false;
msg.forEach(e => {
this.send( msgmodes[mode].replace("{recipient}", recipient).replace("{msg}", e) ); this.send( msgmodes[mode].replace("{recipient}", recipient).replace("{msg}", e) );
}); });
} }