mirror of
https://github.com/willmiao/ComfyUI-Lora-Manager.git
synced 2026-03-25 07:05:43 -03:00
Enhance CivitaiClient error handling for unauthorized access
- Updated handling of 401 unauthorized responses to differentiate between API key issues and early access restrictions. - Improved logging for unauthorized access attempts. - Refactored condition to check for early access restrictions based on response headers. - Adjusted logic in DownloadManager to check for early access using a more concise method.
This commit is contained in:
@@ -29,7 +29,7 @@ class DownloadManager:
|
||||
return {'success': False, 'error': 'Failed to fetch model metadata'}
|
||||
|
||||
# Check if this is an early access LoRA
|
||||
if 'earlyAccessEndsAt' in version_info:
|
||||
if version_info.get('earlyAccessEndsAt'):
|
||||
early_access_date = version_info.get('earlyAccessEndsAt', '')
|
||||
# Convert to a readable date if possible
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user