From 801e9d1cd96b4e15ef899a0a0c83569b33ffefa6 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Fri, 30 Oct 2020 12:02:27 -0400 Subject: [PATCH] Fix --- commands/search/movie.js | 2 +- commands/search/tv-show.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/commands/search/movie.js b/commands/search/movie.js index 69eb5f13..b517dc83 100644 --- a/commands/search/movie.js +++ b/commands/search/movie.js @@ -43,7 +43,7 @@ module.exports = class MovieCommand extends Command { if (!search.body.results.length) return msg.say('Could not find any results.'); let find = search.body.results.find(m => m.title.toLowerCase() === query.toLowerCase()) || search.body.results[0]; - if (search.body.results > 1) { + if (search.body.results.length > 1) { const resultListFunc = (movie, i) => `**${i + 1}.** ${movie.title} (${movie.release_date || 'TBA'})`; find = await pickWhenMany(msg, search.body.results, find, resultListFunc); } diff --git a/commands/search/tv-show.js b/commands/search/tv-show.js index f5823439..1e7b0646 100644 --- a/commands/search/tv-show.js +++ b/commands/search/tv-show.js @@ -43,7 +43,7 @@ module.exports = class TvShowCommand extends Command { if (!search.body.results.length) return msg.say('Could not find any results.'); let find = search.body.results.find(m => m.name.toLowerCase() === query.toLowerCase()) || search.body.results[0]; - if (search.body.results > 1) { + if (search.body.results.length > 1) { const resultListFunc = (show, i) => `**${i + 1}.** ${show.name} (${show.first_air_date || 'TBA'})`; find = await pickWhenMany(msg, search.body.results, find, resultListFunc); }