Bug fixes V2.1 (#467)

* Ultroid 2025 

Co-authored-by: New-dev0 <New-dev0@users.noreply.github.com>
Co-authored-by: Amit Sharma <buddhhu@users.noreply.github.com>
Co-authored-by: TechiError <techierror@users.noreply.github.com>
Co-authored-by: Aditya <me@xditya.me>
Co-authored-by: 1Danish-00 <danish@ultroid.tech> 
Co-authored-by: Arnab Paryali <Arnabxd@users.noreply.github.com>
Co-authored-by: hellboi_atul <hellboi-atul@users.noreply.github.com>
Co-authored-by: sppidy <sppidy@users.noreply.github.com> by Devesh Pal
This commit is contained in:
Devesh Pal
2025-02-23 09:17:26 +05:30
committed by GitHub
parent 9e7a0cf96e
commit c5c7916be6
32 changed files with 564 additions and 381 deletions

View File

@@ -22,7 +22,7 @@
"""
import os
from telegraph import upload_file as uf
from . import upload_file as uf
from telethon.utils import pack_bot_file_id
from pyUltroid.dB.notes_db import add_note, get_notes, list_note, rem_note
@@ -46,16 +46,14 @@ async def an(e):
wut = mediainfo(wt.media)
if wut.startswith(("pic", "gif")):
dl = await wt.download_media()
variable = uf(dl)
m = uf(dl)
os.remove(dl)
m = f"https://graph.org{variable[0]}"
elif wut == "video":
if wt.media.document.size > 8 * 1000 * 1000:
return await e.eor(get_string("com_4"), time=5)
dl = await wt.download_media()
variable = uf(dl)
m = uf(dl)
os.remove(dl)
m = f"https://graph.org{variable[0]}"
else:
m = pack_bot_file_id(wt.media)
if wt.text: