MCPcopy Create free account
hub / github.com/Ember-Moth/ppanel / update_document

Function update_document

src/handler/admin/document/update_document_handler.rs:9–17  ·  view source on GitHub ↗
(
    State(state): State<AppState>,
    Json(req): Json<UpdateDocumentRequest>,
)

Source from the content-addressed store, hash-verified

7use result::http_result::{build_http_result, HttpResult};
8
9pub async fn update_document(
10 State(state): State<AppState>,
11 Json(req): Json<UpdateDocumentRequest>,
12) -> HttpResult {
13 match update_document_service::update_document(state.repos.document.as_ref(), req).await {
14 Ok(()) => build_http_result(Some(()), None),
15 Err(e) => build_http_result::<()>(None, Some(e)),
16 }
17}

Callers

nothing calls this directly

Calls 1

build_http_resultFunction · 0.85

Tested by

no test coverage detected