BackupClient: add upload() function
This commit is contained in:
parent
6d4df36c3c
commit
15bb1bba89
|
@ -601,6 +601,15 @@ impl BackupClient {
|
||||||
self.h2.post(path, param).await
|
self.h2.post(path, param).await
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub async fn upload(
|
||||||
|
&self,
|
||||||
|
path: &str,
|
||||||
|
param: Option<Value>,
|
||||||
|
data: Vec<u8>,
|
||||||
|
) -> Result<Value, Error> {
|
||||||
|
self.h2.upload(path, param, data).await
|
||||||
|
}
|
||||||
|
|
||||||
pub async fn finish(self: Arc<Self>) -> Result<(), Error> {
|
pub async fn finish(self: Arc<Self>) -> Result<(), Error> {
|
||||||
let h2 = self.h2.clone();
|
let h2 = self.h2.clone();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue