fix: extension + file permissions

This commit is contained in:
relikd
2025-10-15 18:20:11 +02:00
parent 4f160cefcd
commit d342f42290
7 changed files with 3 additions and 1 deletions

0
botlib/__init__.py Executable file → Normal file
View File

0
botlib/cli.py Executable file → Normal file
View File

0
botlib/cron.py Executable file → Normal file
View File

4
botlib/curl.py Executable file → Normal file
View File

@@ -184,7 +184,9 @@ class Curl:
if not parts:
raise URLError('URL not valid: "{}"'.format(url_str))
ext = parts.path.split('.')[-1] or 'unknown'
ext = parts.path.split('.')[-1]
if not ext or len(ext) > 4:
ext = 'unknown'
file_path = os.path.join(dest_dir, fname + '.' + ext)
if override or not os.path.isfile(file_path):
url = parts.geturl()

0
botlib/helper.py Executable file → Normal file
View File

0
botlib/oncedb.py Executable file → Normal file
View File

0
botlib/tgclient.py Executable file → Normal file
View File