Trim MOTD to avoid empty line at the end

This commit is contained in:
Pavel Djundik 2018-02-13 12:38:33 +02:00
parent f7449c565f
commit fa993c29d5

View File

@ -9,7 +9,7 @@ module.exports = function(irc, network) {
const lobby = network.channels[0]; const lobby = network.channels[0];
if (data.motd) { if (data.motd) {
data.motd.split("\n").forEach((text) => { data.motd.trim().split("\n").forEach((text) => {
const msg = new Msg({ const msg = new Msg({
type: Msg.Type.MOTD, type: Msg.Type.MOTD,
text: text, text: text,