Skip to content

Commit

Permalink
fix: model_path string
Browse files Browse the repository at this point in the history
  • Loading branch information
sangjanai committed Jul 9, 2024
1 parent fcbdb51 commit c245d9e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/audio_engine.cc
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,8 @@ bool AudioEngine::LoadModelImpl(std::shared_ptr<Json::Value> json_body) {
}

server_map_[model_id].ctx.model_id = model_id;
auto is_success = server_map_[model_id].ctx.LoadModel(model_path.asString());
auto model_path_str = model_path.asString();
auto is_success = server_map_[model_id].ctx.LoadModel(model_path_str);
if (!is_success) {
LOG_ERROR << "Could not load model: " << model_path.asString();
server_map_.erase(model_id);
Expand Down

0 comments on commit c245d9e

Please sign in to comment.