diff --git a/src/core/orchestrator.rs b/src/core/orchestrator.rs index 7cfacf5..182e989 100644 --- a/src/core/orchestrator.rs +++ b/src/core/orchestrator.rs @@ -307,13 +307,13 @@ impl Orchestrator

{ /// /// Matches on known tool names to extract structured fields; falls back to /// `Generic` with a JSON summary for anything else. - fn build_tool_display(&self, tool_name: &str, input: &serde_json::Value) -> ToolDisplay { + async fn build_tool_display(&self, tool_name: &str, input: &serde_json::Value) -> ToolDisplay { match tool_name { "write_file" => { let path = input["path"].as_str().unwrap_or("").to_string(); let new_content = input["content"].as_str().unwrap_or("").to_string(); // Try to read existing content for diffing. - let old_content = self.sandbox.read_file(&path).ok(); + let old_content = self.sandbox.read_file(&path).await.ok(); ToolDisplay::WriteFile { path, old_content, @@ -405,7 +405,7 @@ impl Orchestrator

{ } }; - let display = self.build_tool_display(tool_name, input); + let display = self.build_tool_display(tool_name, input).await; // Check approval. let approved = match risk {