diff --git a/youtube_dl_gui/utils.py b/youtube_dl_gui/utils.py index 1ed13dc..f19f330 100644 --- a/youtube_dl_gui/utils.py +++ b/youtube_dl_gui/utils.py @@ -106,6 +106,12 @@ os_path_expanduser = convert_on_bounds(os.path.expanduser) if os.name == 'nt': os_startfile = convert_on_bounds(os.startfile) +def remove_file(filename): + if os_path_exists(filename): + os.remove(filename) + return True + + return False def remove_shortcuts(path): """Return given path after removing the shortcuts. """