This commit is contained in:
levina 2022-01-21 23:42:01 +07:00 committed by GitHub
parent 2fcc60e8e6
commit acab501af3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -42,7 +42,7 @@ ydl_opts = {
def song(_, message):
query = " ".join(message.command[1:])
m = message.reply("🔎 finding song...")
ydl_ops = {"format": "bestaudio[ext=m4a]"}
ydl_ops = {"format": "bestaudio/best"}
try:
results = YoutubeSearch(query, max_results=1).to_dict()
link = f"https://youtube.com{results[0]['url_suffix']}"