Spaces:
Runtime error
Runtime error
Commit
•
8120649
1
Parent(s):
fd01f63
Update app.py
Browse files
app.py
CHANGED
@@ -358,8 +358,9 @@ def add_custom_lora(custom_lora, selected_indices):
|
|
358 |
print(f"Loaded custom LoRA: {repo}")
|
359 |
existing_item_index = next((index for (index, item) in enumerate(loras) if item['repo'] == repo), None)
|
360 |
if existing_item_index is None:
|
361 |
-
if(repo.endswith(".safetensors")):
|
362 |
-
downloaded_path = download_file(
|
|
|
363 |
new_item = {
|
364 |
"image": image if image is not None else "",
|
365 |
"title": title,
|
|
|
358 |
print(f"Loaded custom LoRA: {repo}")
|
359 |
existing_item_index = next((index for (index, item) in enumerate(loras) if item['repo'] == repo), None)
|
360 |
if existing_item_index is None:
|
361 |
+
if(repo.endswith(".safetensors") and repo.startswith("http")):
|
362 |
+
downloaded_path = download_file(repo)
|
363 |
+
|
364 |
new_item = {
|
365 |
"image": image if image is not None else "",
|
366 |
"title": title,
|