fallback for artist name in youtube

This commit is contained in:
Hellow 2023-07-27 20:49:08 +02:00
parent fe1751a7f3
commit ec6e55befe

View File

@ -238,6 +238,10 @@ class YouTube(Page):
for artist_name in music_track["artist"].split(" x "):
artist_list.append(Artist(name=artist_name))
# if all attempts to get a clean artis name (mainly striping topic or getting the stuff in the api) fail, just add an artist with the name of the uploader channel
if len(artist_list) == 0:
artist_list.append(Artist(_author))
return Song(
title=title,
source_list=[Source(