From 1c8afc16cc5192e1b93cdacbc494a832c4847bbe Mon Sep 17 00:00:00 2001 From: ksyasuda Date: Sun, 10 Jul 2022 05:26:30 -0700 Subject: [PATCH] fix infinite loop on no results found --- ani-cli | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/ani-cli b/ani-cli index 50e9eed..0b13b42 100755 --- a/ani-cli +++ b/ani-cli @@ -299,12 +299,7 @@ search_anime() { process_search() { progress "Searching $query.." search_results=$(search_anime "$query") - while [ -z "$search_results" ]; do - retry 'No search results found' - query="$REPLY $REPLY2" - progress "Searching $scrape.." - search_results=$(search_anime "$query") - done + [ -z "$search_results" ] && die 'No search results found' lg "Search Results: $search_results" printf "%s\n" "$search_results" }