proxmox-rest-server: cleanup formatter, improve docs

Use trait for OutputFormatter. This is functionally equivalent,
but more rust-like...
This commit is contained in:
Dietmar Maurer
2021-09-27 12:59:06 +02:00
parent 8a23ea4656
commit 53daae8e89
8 changed files with 128 additions and 98 deletions

View File

@ -1332,7 +1332,7 @@ pub fn upload_backup_log(
replace_file(&path, blob.raw_data(), CreateOptions::new())?;
// fixme: use correct formatter
Ok(formatter::json_response(Ok(Value::Null)))
Ok(formatter::JSON_FORMATTER.format_data(Value::Null, &*rpcenv))
}.boxed()
}