mirror of
https://github.com/willmiao/ComfyUI-Lora-Manager.git
synced 2026-03-24 06:32:12 -03:00
feat(metadata): enhance model processing with CivitAI metadata checks and new fields for archive DB status
This commit is contained in:
@@ -626,18 +626,16 @@ class BaseModelRoutes(ABC):
|
||||
|
||||
# Prepare models to process, only those without CivitAI data
|
||||
enable_metadata_archive_db = settings.get('enable_metadata_archive_db', False)
|
||||
# Filter models that need CivitAI metadata update
|
||||
to_process = [
|
||||
model for model in cache.raw_data
|
||||
if (
|
||||
model.get('sha256')
|
||||
and (
|
||||
not model.get('civitai')
|
||||
or not model['civitai'].get('id')
|
||||
)
|
||||
and (
|
||||
(enable_metadata_archive_db)
|
||||
or (not enable_metadata_archive_db and model.get('from_civitai') is True)
|
||||
)
|
||||
if model.get('sha256')
|
||||
and (
|
||||
not model.get('civitai') or not model['civitai'].get('id')
|
||||
)
|
||||
and (
|
||||
(enable_metadata_archive_db and not model.get('db_checked', False))
|
||||
or (not enable_metadata_archive_db and model.get('from_civitai') is True)
|
||||
)
|
||||
]
|
||||
total_to_process = len(to_process)
|
||||
|
||||
Reference in New Issue
Block a user