diff --git a/model_filemanager/download_models.py b/model_filemanager/download_models.py index 0a59f001e..406e35883 100644 --- a/model_filemanager/download_models.py +++ b/model_filemanager/download_models.py @@ -180,7 +180,9 @@ async def handle_download_error(e: Exception, def validate_model_subdirectory(model_subdirectory: str) -> bool: """ - Validate that the model subdirectory is safe. + Validate that the model subdirectory is safe to install into. + Must not contain relative paths, nested paths or special characters + other than underscores and hyphens. Args: model_subdirectory (str): The subdirectory for the specific model type.