Code:
const { EmbedBuilder } = require("discord.js");
const got = require("got");
module.exports = {
name: "meme",
description: "Shows an image of a meme!",
run: async (client, message, args) => {
got("https://www.reddit.com/r/memes/random/.json").then(response => {
const [list] = JSON.parse(response.body);
const [post] = list.data.children;
const permalink = post.data.permalink;
const memeUrl = `https://reddit.com${post.data.permalink}`;
const memeImage = post.data.url;
const memeTitle = post.data.title;
const memeUpvotes = post.data.ups;
const memeNumComments = post.data.num_comments;
const memeEmbed = new EmbedBuilder()
.setTitle(`${memeTitle}`)
.setURL(`${memeUrl}`)
.setColor("Random")
.setImage(memeImage)
.setFooter({ text: `