From dccb833e36e750104aee11735778dca0ca9a6616 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Sat, 30 Mar 2024 18:59:44 -0400 Subject: [PATCH] Fix --- commands/analyze/saucenao.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/commands/analyze/saucenao.js b/commands/analyze/saucenao.js index 5ee0ddf9..ba2d6de0 100644 --- a/commands/analyze/saucenao.js +++ b/commands/analyze/saucenao.js @@ -29,7 +29,12 @@ module.exports = class SauceNaoCommand extends Command { } async run(msg, { image }) { - const data = await sagiriClient(image); + let data; + try { + data = await sagiriClient(image); + } catch { + return msg.reply('No results for this image.'); + } if (!data.length) return msg.reply('No results for this image.'); const sauce = data[0]; const embed = new MessageEmbed()