Updated for typing

This commit is contained in:
Dimitris Zlatanidis 2023-04-25 12:06:57 +03:00
parent 776ffc805a
commit 48f45e7709

View file

@ -17,7 +17,7 @@ class Downloader(Configs):
def __init__(self, path: Union[str, Path], urls: list, flags: list):
__slots__ = 'path', 'urls', 'flags'
super(Configs, self).__init__()
self.path = path
self.path: Path = path
self.urls: list = urls
self.flags: list = flags
@ -70,7 +70,7 @@ class Downloader(Configs):
""" Checks if the file downloaded. """
url: str = unquote(url)
file: str = url.split('/')[-1]
path_file = Path(self.path, file)
path_file: Path = Path(self.path, file)
if not path_file.exists():
self.errors.raise_error_message(f"Download the '{file}' file")