mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-03 23:36:43 +02:00
Wikipedia Fixes (Again)
This commit is contained in:
@@ -29,12 +29,12 @@ class WikipediaCommand extends commando.Command {
|
||||
request(options).then(function (response) {
|
||||
let description = response.query.pages[0].extract;
|
||||
let name = response.query.pages[0].title;
|
||||
description = description.substr(0, 1900);
|
||||
description = description.replace(/\n/, "\n\n");
|
||||
wikied = wikied.replace(")", "%29");
|
||||
if(description === undefined) {
|
||||
message.channel.sendMessage(":x: Error! Entry Not Found!");
|
||||
} else {
|
||||
description = description.substr(0, 1900);
|
||||
description = description.replace(/\n/, "\n\n");
|
||||
if(description.length > 1900) {
|
||||
const embed = new Discord.RichEmbed()
|
||||
.setColor(0xE7E7E7)
|
||||
|
||||
Reference in New Issue
Block a user