Fix of metadata loading

This commit is contained in:
2023-06-22 18:44:17 +02:00
parent d0c59a884c
commit 3fd99ce5c4
+4
View File
@@ -1310,6 +1310,7 @@ async def zrob_mi_plejliste(ctx):
MUZYKA["queue"].insert(0, plik[1])
MUZYKA["requestor"].insert(0, ctx.author)
metadata = eyed3.load(plik[1])
if metadata and metadata.tag:
if metadata.tag.title:
reply += f"{index} {metadata.tag.title}"
else:
@@ -1323,6 +1324,9 @@ async def zrob_mi_plejliste(ctx):
reply += (
" z prywatnej kolekcji Hammera i na Twoją specjalną rpośbę.\n"
)
else:
reply += "{index}. {plik[1]} z prywatnej kolekcji Hammera."
index += 1
if len(reply) > 1800:
await ctx.send(reply)