Proper \n Splitting in Wikipedia Command

This commit is contained in:
dragonfire535
2017-03-12 00:23:30 -05:00
parent 1f2a2610ac
commit c99995d48f
+1 -1
View File
@@ -34,7 +34,7 @@ class WikipediaCommand extends commando.Command {
message.channel.sendMessage(":x: Error! Entry Not Found!");
} else {
description = description.substr(0, 1900);
description = description.replace(/\n/, "\n\n");
description = description.split('\n').join("\n\n");
if(description.length > 1900) {
const embed = new Discord.RichEmbed()
.setColor(0xE7E7E7)