(
Path(id): Path<String>,
Json(req): Json<UpdatePtyRequest>,
)
| 3428 | } |
| 3429 | |
| 3430 | async fn update_pty( |
| 3431 | Path(id): Path<String>, |
| 3432 | Json(req): Json<UpdatePtyRequest>, |
| 3433 | ) -> Result<Json<PtyInfo>> { |
| 3434 | let manager = get_pty_manager(); |
| 3435 | let session = manager |
| 3436 | .update_session(&id, req.command.as_deref(), req.cwd.as_deref()) |
| 3437 | .await |
| 3438 | .map_err(|e| ApiError::NotFound(e.to_string()))?; |
| 3439 | Ok(Json(PtyInfo::from(session))) |
| 3440 | } |
| 3441 | |
| 3442 | async fn delete_pty(Path(id): Path<String>) -> Result<Json<bool>> { |
| 3443 | let manager = get_pty_manager(); |
nothing calls this directly
no test coverage detected