(
store: Store,
question: Question,
)
| 53 | } |
| 54 | |
| 55 | pub async fn add_question( |
| 56 | store: Store, |
| 57 | question: Question, |
| 58 | ) -> Result<impl warp::Reply, warp::Rejection> { |
| 59 | store |
| 60 | .questions |
| 61 | .write() |
| 62 | .await |
| 63 | .insert(question.clone().id, question); |
| 64 | |
| 65 | Ok(warp::reply::with_status("Question added", StatusCode::OK)) |
| 66 | } |
nothing calls this directly
no outgoing calls
no test coverage detected