diff --git a/assets/json/news.json b/assets/json/news.json index d087864e..aba06455 100644 --- a/assets/json/news.json +++ b/assets/json/news.json @@ -32,7 +32,7 @@ "climate", "business", "energy", - "crpytomarkets", + "cryptomarkets", "mlb", "nature", "finance", diff --git a/package.json b/package.json index ca36ed9b..7bf392a8 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "xiao", - "version": "116.9.0", + "version": "116.9.1", "description": "Your personal server companion.", "main": "Xiao.js", "scripts": { diff --git a/structures/commands/Subreddit.js b/structures/commands/Subreddit.js index 1c7bb0f6..92471a4e 100644 --- a/structures/commands/Subreddit.js +++ b/structures/commands/Subreddit.js @@ -45,7 +45,7 @@ module.exports = class SubredditCommand extends Command { .setURL(`https://www.reddit.com${post.permalink}`) .setTimestamp(post.created_utc * 1000) .setFooter(`⬆ ${formatNumberK(post.ups)}`); - if (post.thumbnail && post.thumbnail !== 'self' && post.post_hint !== 'image') { + if (post.thumbnail && post.thumbnail !== 'self' && post.thumbnail !== 'default' && post.post_hint !== 'image') { embed.setThumbnail(post.thumbnail); } return embed; @@ -74,6 +74,6 @@ module.exports = class SubredditCommand extends Command { async fetchIcon(subreddit) { const { body } = await request.get(`https://www.reddit.com/r/${subreddit}/about.json`); if (!body.data.icon_img && !body.data.community_icon) return 'https://i.imgur.com/DSBOK0P.png'; - return body.data.icon_img || body.data.community_icon; + return body.data.icon_img || body.data.community_icon.replace(/\?.+/, ''); } };