Skip to content
This repository was archived by the owner on Jul 16, 2022. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions Commands/Public/fox.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
const { RandomAnimals } = require("../../Modules/");

module.exports = async ({ Constants: { Colors } }, documents, msg, commandData) => {
await msg.send({
embed: {
color: Colors.INFO,
title: `We're getting you a cute fox picture 🦊`,
description: `Please stand by...`,
},
});
try {
const dog = await RandomAnimals.fox();
if (fox) {
msg.send({
embed: {
color: Colors.LIGHT_GREEN,
title: `Here's your adorale fox picture! 🦊`,
image: {
url: "https://foxapi.dev/foxes",
},
},
});
}
} catch (err) {
return msg.send({
embed: {
color: Colors.SOFT_ERR,
description: `I failed to fetch a fox picture...`,
footer: {
text: `Pwease try again...`,
},
},
});
}
};