view_task_result: remove unnecessary &mut
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
This commit is contained in:
parent
aa174e8e8a
commit
8ff886773f
@ -91,11 +91,11 @@ async fn create_datastore(mut param: Value) -> Result<Value, Error> {
|
||||
|
||||
let output_format = extract_output_format(&mut param);
|
||||
|
||||
let mut client = connect_to_localhost()?;
|
||||
let client = connect_to_localhost()?;
|
||||
|
||||
let result = client.post("api2/json/config/datastore", Some(param)).await?;
|
||||
|
||||
view_task_result(&mut client, result, &output_format).await?;
|
||||
view_task_result(&client, result, &output_format).await?;
|
||||
|
||||
Ok(Value::Null)
|
||||
}
|
||||
|
@ -93,11 +93,11 @@ async fn run_tape_backup_job(mut param: Value) -> Result<(), Error> {
|
||||
|
||||
let id = param["id"].take().as_str().unwrap().to_string();
|
||||
|
||||
let mut client = connect_to_localhost()?;
|
||||
let client = connect_to_localhost()?;
|
||||
|
||||
let result = client.post(&format!("api2/json/tape/backup/{}", id), Some(param)).await?;
|
||||
|
||||
view_task_result(&mut client, result, &output_format).await?;
|
||||
view_task_result(&client, result, &output_format).await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user