diff --git a/idc_index/index.py b/idc_index/index.py index a8671a0f..2efea596 100644 --- a/idc_index/index.py +++ b/idc_index/index.py @@ -733,6 +733,10 @@ def download_from_selection( TypeError: If any of the parameters are not of the expected type """ + downloadDir = os.path.abspath(downloadDir).replace("\\", "/") + if not os.path.exists(downloadDir): + raise ValueError("Download directory does not exist.") + if collection_id is not None: if not isinstance(collection_id, str) and not isinstance( collection_id, list