snekfetch 4.0.0

This commit is contained in:
Daniel Odendahl Jr
2018-04-24 21:27:16 +00:00
parent 6030c024c1
commit d26af498ad
27 changed files with 56 additions and 49 deletions
+1 -1
View File
@@ -50,7 +50,7 @@ module.exports = class GitHubCommand extends Command {
.addField(' Modification Date', new Date(body.updated_at).toDateString(), true);
return msg.embed(embed);
} catch (err) {
if (err.status === 404) return msg.say('Could not find any results.');
if (err.statusCode === 404) return msg.say('Could not find any results.');
return msg.reply(`Oh no, an error occurred: \`${err.message}\`. Try again later!`);
}
}