(
coordinator: State<'_, Arc<ConversationCoordinator>>,
app_state: State<'_, AppState>,
request: ClearSessionThreadGoalRequest,
)
| 1090 | |
| 1091 | #[tauri::command] |
| 1092 | pub async fn clear_session_thread_goal( |
| 1093 | coordinator: State<'_, Arc<ConversationCoordinator>>, |
| 1094 | app_state: State<'_, AppState>, |
| 1095 | request: ClearSessionThreadGoalRequest, |
| 1096 | ) -> Result<(), String> { |
| 1097 | let session_id = request.session_id.trim(); |
| 1098 | if session_id.is_empty() { |
| 1099 | return Err("session_id is required".to_string()); |
| 1100 | } |
| 1101 | let workspace_path = ensure_session_for_thread_goal( |
| 1102 | coordinator.inner(), |
| 1103 | app_state.inner(), |
| 1104 | session_id, |
| 1105 | request.workspace_path.as_deref(), |
| 1106 | request.remote_connection_id.as_deref(), |
| 1107 | request.remote_ssh_host.as_deref(), |
| 1108 | ) |
| 1109 | .await?; |
| 1110 | coordinator |
| 1111 | .clear_thread_goal(session_id, workspace_path.as_path()) |
| 1112 | .await |
| 1113 | .map_err(|error| error.to_string()) |
| 1114 | } |
| 1115 | |
| 1116 | #[tauri::command] |
| 1117 | pub async fn set_session_thread_goal_status( |
nothing calls this directly
no test coverage detected