This commit is contained in:
Dragon Fire
2020-10-30 12:02:27 -04:00
parent 2409d97e83
commit 801e9d1cd9
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -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);
}
+1 -1
View File
@@ -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);
}