summaryrefslogtreecommitdiff
path: root/src/cmd/restore.rs
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2022-01-16 17:15:52 +0200
committerLars Wirzenius <liw@liw.fi>2022-01-16 17:33:09 +0200
commit6ed7241df0accea0d06beefa6aa39543b3a138e3 (patch)
tree1ddb56e4a431421043bd72d38a895f2bd73f23ea /src/cmd/restore.rs
parent61ea591bd254a240bb8c45221dea057c1517b0ae (diff)
downloadobnam2-6ed7241df0accea0d06beefa6aa39543b3a138e3.tar.gz
refactor: rename AsyncBackupClient to just BackupClient
There is only async. Sponsored-by: author
Diffstat (limited to 'src/cmd/restore.rs')
-rw-r--r--src/cmd/restore.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/cmd/restore.rs b/src/cmd/restore.rs
index 2a36986..7b3d95e 100644
--- a/src/cmd/restore.rs
+++ b/src/cmd/restore.rs
@@ -1,7 +1,7 @@
//! The `restore` subcommand.
use crate::backup_reason::Reason;
-use crate::client::{AsyncBackupClient, ClientError};
+use crate::client::{BackupClient, ClientError};
use crate::config::ClientConfig;
use crate::error::ObnamError;
use crate::fsentry::{FilesystemEntry, FilesystemKind};
@@ -43,7 +43,7 @@ impl Restore {
async fn run_async(&self, config: &ClientConfig) -> Result<(), ObnamError> {
let temp = NamedTempFile::new()?;
- let client = AsyncBackupClient::new(config)?;
+ let client = BackupClient::new(config)?;
let genlist = client.list_generations().await?;
let gen_id = genlist.resolve(&self.gen_id)?;
@@ -130,7 +130,7 @@ pub enum RestoreError {
}
async fn restore_generation(
- client: &AsyncBackupClient,
+ client: &BackupClient,
gen: &LocalGeneration,
fileid: i64,
entry: &FilesystemEntry,
@@ -182,7 +182,7 @@ fn restored_path(entry: &FilesystemEntry, to: &Path) -> Result<PathBuf, RestoreE
}
async fn restore_regular(
- client: &AsyncBackupClient,
+ client: &BackupClient,
gen: &LocalGeneration,
path: &Path,
fileid: i64,