|
@@ -22,8 +22,6 @@ ydl_opts = {
|
|
|
|
|
|
|
|
@app.on_message(cust_filter.command(commands=(["music"])))
|
|
@app.on_message(cust_filter.command(commands=(["music"])))
|
|
|
async def commit(client, message):
|
|
async def commit(client, message):
|
|
|
- user_id = message.from_user.id
|
|
|
|
|
- user_name = message.from_user.username
|
|
|
|
|
app.set_parse_mode("markdown")
|
|
app.set_parse_mode("markdown")
|
|
|
await message.reply_chat_action("upload_audio")
|
|
await message.reply_chat_action("upload_audio")
|
|
|
link = (message.text.split(None, 1)[1])
|
|
link = (message.text.split(None, 1)[1])
|
|
@@ -31,7 +29,6 @@ async def commit(client, message):
|
|
|
ydl.download([link])
|
|
ydl.download([link])
|
|
|
for filename in glob.glob("*.mp3"):
|
|
for filename in glob.glob("*.mp3"):
|
|
|
m = await message.reply_audio(filename)
|
|
m = await message.reply_audio(filename)
|
|
|
- await m.edit_caption(f'''
|
|
|
|
|
-[Source]({link})''')
|
|
|
|
|
|
|
+ await m.edit_caption(f"[{filename}]({link})")
|
|
|
os.remove(filename)
|
|
os.remove(filename)
|
|
|
|
|
|