mirror of
https://github.com/willmiao/ComfyUI-Lora-Manager.git
synced 2026-03-21 21:22:11 -03:00
feat: Enhance relative path handling in download manager to include base model
This commit is contained in:
@@ -96,10 +96,14 @@ class DownloadManager:
|
||||
return {'success': False, 'error': 'Default lora root path not set in settings'}
|
||||
save_dir = default_path
|
||||
|
||||
# Set relative_path to the first tag if available
|
||||
# Set relative_path to version_info.baseModel/first_tag if available
|
||||
base_model = version_info.get('baseModel', '')
|
||||
model_tags = version_info.get('model', {}).get('tags', [])
|
||||
if model_tags:
|
||||
relative_path = model_tags[0]
|
||||
if base_model:
|
||||
if model_tags:
|
||||
relative_path = os.path.join(base_model, model_tags[0])
|
||||
else:
|
||||
relative_path = base_model
|
||||
|
||||
# Update save directory with relative path if provided
|
||||
if relative_path:
|
||||
|
||||
Reference in New Issue
Block a user