This commit is contained in:
Dragon Fire
2021-08-02 20:09:01 -04:00
parent e2eed5d3bf
commit 0ba5f71e06
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
const { Message, MessagePayload, APIMessage } = require('discord.js');
const { Message } = require('discord.js');
Reflect.defineProperty(Message.prototype, 'say', { value: function (content, options) {
if (typeof content === 'object') return this.channel.send(content);
+1 -1
View File
@@ -23,7 +23,7 @@ module.exports = class SubredditCommand extends Command {
try {
const post = await this.random(subreddit, msg.channel.nsfw);
if (!post) return msg.reply('Could not find any results.');
return msg.say(this.generateText(post.post, post.origin, post.icon));
return msg.embed(this.generateText(post.post, post.origin, post.icon));
} catch (err) {
if (err.status === 403) return msg.say('This subreddit is private.');
if (err.status === 404) return msg.say('Could not find any results.');