send url to be sure it will always work

This commit is contained in:
Loïc Bersier 2019-06-26 04:21:28 +02:00
parent 558a789e92
commit 6c67cd5a79

View file

@ -45,12 +45,12 @@ class RedditCommand extends Command {
const redditEmbed = new MessageEmbed()
.setColor('#ff9900')
.setTitle(response.data.children[i].data.title)
.setImage(response.data.children[i].data.url)
.setDescription(response.data.children[i].data.selftext)
.setURL('https://reddit.com' + response.data.children[i].data.permalink)
.setFooter(`/r/${response.data.children[i].data.subreddit} | ⬆ ${response.data.children[i].data.ups}${response.data.children[i].data.num_comments}`);
message.channel.send(redditEmbed);
message.channel.send(response.data.children[i].data.url);
});
}
}