fixed crash

This commit is contained in:
Hellow2 2023-04-05 10:25:55 +02:00
parent ad0638b82c
commit 8e19c68e36
2 changed files with 4 additions and 2 deletions

View File

@ -50,4 +50,4 @@ def real_download():
if __name__ == "__main__":
music_kraken.cli(genre="test")
music_kraken.cli(genre=None)

View File

@ -60,6 +60,8 @@ def cli(genre: str = None, download_all: bool = False):
if not any(re.match(regex_pattern, name) for regex_pattern in NOT_A_GENRE_REGEX):
existing_genres.append(name)
existing_genres.sort()
return existing_genres
def get_genre():
@ -147,7 +149,7 @@ def cli(genre: str = None, download_all: bool = False):
search = pages.Search()
while True:
if next_search(search, input(">> "), genre, download_all):
if next_search(search, input(">> ")):
break
print(search)