mirror of
https://github.com/typesense/typesense.git
synced 2025-05-24 07:40:35 +08:00
Fix error message when Huggingface is down (#1586)
* Fix error message when Huggingface is down * Edit message
This commit is contained in:
parent
f608656393
commit
eb6ab00397
@ -485,6 +485,10 @@ Option<nlohmann::json> EmbedderManager::get_public_model_config(const std::strin
|
||||
return Option<nlohmann::json>(config);
|
||||
}
|
||||
|
||||
if(res >= 500) {
|
||||
return Option<nlohmann::json>(res, "Model repository is down. Status code: " + std::to_string(res));
|
||||
}
|
||||
|
||||
return Option<nlohmann::json>(404, "Model not found");
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user