mirror of
https://github.com/Arrowar/StreamingCommunity.git
synced 2025-06-03 10:00:10 +00:00
core: MP4 add sanitize path
This commit is contained in:
parent
a376556f60
commit
74218e3101
@ -21,7 +21,7 @@ from rich.panel import Panel
|
||||
from StreamingCommunity.Util.headers import get_userAgent
|
||||
from StreamingCommunity.Util.color import Colors
|
||||
from StreamingCommunity.Util.config_json import config_manager
|
||||
from StreamingCommunity.Util.os import internet_manager
|
||||
from StreamingCommunity.Util.os import internet_manager, os_manager
|
||||
from StreamingCommunity.TelegramHelp.telegram_bot import get_bot_instance
|
||||
|
||||
|
||||
@ -80,6 +80,7 @@ def MP4_downloader(url: str, path: str, referer: str = None, headers_: dict = No
|
||||
bot = get_bot_instance()
|
||||
console.log("####")
|
||||
|
||||
path = os_manager.get_sanitize_path(path)
|
||||
if os.path.exists(path):
|
||||
console.log("[red]Output file already exists.")
|
||||
if TELEGRAM_BOT:
|
||||
|
Loading…
x
Reference in New Issue
Block a user