This commit is contained in:
Dragon Fire
2019-06-28 18:16:51 -04:00
parent 3c9d7a31c5
commit 9b458f5a9c
+1 -1
View File
@@ -45,7 +45,7 @@ module.exports = class NeopetCommand extends Command {
async run(msg, { pet, mood }) {
try {
const { body } = await request.get(`http://pets.neopets.com/cpn/${encodeURIComponent(name)}/${mood}/5.png`);
const { body } = await request.get(`http://pets.neopets.com/cpn/${encodeURIComponent(pet)}/${mood}/5.png`);
return msg.say({ files: [{ attachment: body, name: `${pet}-${mood}.png` }] });
} catch (err) {
if (err.status === 404) return msg.say('Could not find any results.');