From 26b37e3d485f6082783fa076194e26d49efa20bf Mon Sep 17 00:00:00 2001 From: levina <82658782+levina-lab@users.noreply.github.com> Date: Mon, 21 Feb 2022 08:27:30 +0700 Subject: [PATCH] [check] some changes --- program/music.py | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/program/music.py b/program/music.py index f1c0fa2..e73818c 100644 --- a/program/music.py +++ b/program/music.py @@ -84,7 +84,7 @@ async def play_tg_file(c: Client, m: Message, replied: Message = None, link: str suhu = await m.reply("📥 downloading audio...") dl = await replied.download() link = replied.link - songname = "Audio" + songname = "music" thumbnail = f"{IMG_5}" duration = "00:00" try: @@ -100,7 +100,7 @@ async def play_tg_file(c: Client, m: Message, replied: Message = None, link: str thumbnail = await user.download_media(replied.audio.thumbs[0].file_id) duration = convert_seconds(replied.audio.duration) elif replied.voice: - songname = "Voice Note" + songname = "voice note" duration = convert_seconds(replied.voice.duration) except BaseException: pass @@ -115,7 +115,7 @@ async def play_tg_file(c: Client, m: Message, replied: Message = None, link: str title = songname userid = m.from_user.id image = await thumb(thumbnail, title, userid, ctitle) - pos = add_to_queue(chat_id, songname, dl, link, "Audio", 0) + pos = add_to_queue(chat_id, songname, dl, link, "music", 0) requester = f"[{m.from_user.first_name}](tg://user?id={m.from_user.id})" buttons = stream_markup(user_id) await suhu.delete() @@ -146,7 +146,7 @@ async def play_tg_file(c: Client, m: Message, replied: Message = None, link: str ), stream_type=StreamType().pulse_stream, ) - add_to_queue(chat_id, songname, dl, link, "Audio", 0) + add_to_queue(chat_id, songname, dl, link, "music", 0) await suhu.delete() buttons = stream_markup(user_id) requester = ( @@ -231,7 +231,7 @@ async def play(c: Client, m: Message): query = m.text.split(None, 1)[1] search = ytsearch(query) if search == 0: - await suhu.edit("❌ **no results found.**") + await suhu.edit("❌ **no results found**") else: songname = search[0] title = search[0] @@ -249,7 +249,7 @@ async def play(c: Client, m: Message): if chat_id in QUEUE: await suhu.edit("🔄 Queueing Track...") pos = add_to_queue( - chat_id, songname, ytlink, url, "Audio", 0 + chat_id, songname, ytlink, url, "music", 0 ) await suhu.delete() buttons = stream_markup(user_id) @@ -273,7 +273,7 @@ async def play(c: Client, m: Message): ), stream_type=StreamType().local_stream, ) - add_to_queue(chat_id, songname, ytlink, url, "Audio", 0) + add_to_queue(chat_id, songname, ytlink, url, "music", 0) await suhu.delete() buttons = stream_markup(user_id) requester = ( @@ -323,7 +323,7 @@ async def play(c: Client, m: Message): else: if chat_id in QUEUE: await suhu.edit("🔄 Queueing Track...") - pos = add_to_queue(chat_id, songname, ytlink, url, "Audio", 0) + pos = add_to_queue(chat_id, songname, ytlink, url, "music", 0) await suhu.delete() requester = f"[{m.from_user.first_name}](tg://user?id={m.from_user.id})" buttons = stream_markup(user_id) @@ -346,7 +346,7 @@ async def play(c: Client, m: Message): ), stream_type=StreamType().local_stream, ) - add_to_queue(chat_id, songname, ytlink, url, "Audio", 0) + add_to_queue(chat_id, songname, ytlink, url, "music", 0) await suhu.delete() requester = f"[{m.from_user.first_name}](tg://user?id={m.from_user.id})" buttons = stream_markup(user_id)