Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.

Commit fcee871

Browse files
fix: return model_id instead of error if model is already downloaded (#1524)
* fix: print message if model is already downloaded * fix: format --------- Co-authored-by: vansangpfiev <sang@jan.ai>
1 parent ed7bcef commit fcee871

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

engine/services/model_service.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,7 @@ cpp::result<std::string, std::string> ModelService::HandleUrl(
316316

317317
if (model_entry.has_value()) {
318318
CLI_LOG("Model already downloaded: " << unique_model_id);
319-
return cpp::fail("Please delete the model before downloading again");
319+
return unique_model_id;
320320
}
321321

322322
auto local_path{file_manager_utils::GetModelsContainerPath() /

0 commit comments

Comments
 (0)