add not_implemented handler
This commit is contained in:
parent
f3483594ac
commit
18c4f0b3d5
4 changed files with 38 additions and 3 deletions
|
|
@ -56,6 +56,11 @@ let error req err =
|
|||
Logs.err (fun m -> m "%s: %s" (status_to_string status) hint);
|
||||
respond_json req Api.ErrorDetail.jsont status body
|
||||
|
||||
let not_implemented req =
|
||||
Logs.debug (fun m -> m "Not implemented");
|
||||
let body = error_detail "Not Implemented" in
|
||||
respond_json req Api.ErrorDetail.jsont `Not_implemented body
|
||||
|
||||
let result req jsont res =
|
||||
match res with Error e -> error req e | Ok body -> ok req jsont body
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue