Implement all API according to swagger spec #27

Merged
blek merged 16 commits from delete-upload-api-methods into 0.2-dev 2023-12-14 11:56:46 +01:00
2 changed files with 2 additions and 2 deletions
Showing only changes of commit d277fd451e - Show all commits

View File

@ -17,7 +17,7 @@ pub async fn delete(state: SharedState, body: DeleteFunctionPayload) -> Result<B
return Ok(Box::new(res));
}
if state.config.api.delete {
if (!state.config.api.delete) || (!state.config.api.enabled) {
return Ok(Box::new(function_disabled_err()))
}

View File

@ -9,7 +9,7 @@ pub async fn get_all(state: SharedState) -> Result<Box<dyn Reply>, Rejection> {
return Ok(Box::new(res))
}
if ! state.config.api.get_all {
if (!state.config.api.get_all) || (!state.config.api.enabled) {
return Ok(Box::new(function_disabled_err()))
}