Update Ultroid v0.8
--------- Co-authored-by: Amit Sharma <48654350+buddhhu@users.noreply.github.com> Co-authored-by: Aditya <me@xditya.me> Co-authored-by: Dark <darkbeamer.official@gmail.com> Co-authored-by: buddhhu <amitsharma123234@gmail.com> Co-authored-by: Kaif <88398455+kaif-00z@users.noreply.github.com> Co-authored-by: 1Danish-00 <danish@ultroid.tech> Co-authored-by: TechiError <techierror@gmail.com> Co-authored-by: Dark <59723913+DarkBeamerYT@users.noreply.github.com>
This commit is contained in:
@@ -114,7 +114,7 @@ class UltroidClient(TelegramClient):
|
||||
by_bot = self._bot
|
||||
size = os.path.getsize(file)
|
||||
# Don't show progress bar when file size is less than 5MB.
|
||||
if size < 5 * 2**20:
|
||||
if size < 5 * 2 ** 20:
|
||||
show_progress = False
|
||||
if use_cache and self._cache and self._cache.get("upload_cache"):
|
||||
for files in self._cache["upload_cache"]:
|
||||
@@ -170,11 +170,11 @@ class UltroidClient(TelegramClient):
|
||||
"""Download files in a faster way"""
|
||||
# Set to True and pass event to show progress bar.
|
||||
show_progress = kwargs.get("show_progress", False)
|
||||
filename = kwargs.get("filename", None)
|
||||
filename = kwargs.get("filename", "")
|
||||
if show_progress:
|
||||
event = kwargs["event"]
|
||||
# Don't show progress bar when file size is less than 10MB.
|
||||
if file.size < 10 * 2**20:
|
||||
if file.size < 10 * 2 ** 20:
|
||||
show_progress = False
|
||||
import mimetypes
|
||||
|
||||
|
||||
Reference in New Issue
Block a user