cargo fmt
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
22cfad134f
commit
8122eaadaa
@ -598,7 +598,8 @@ pub fn list_snapshots(
|
||||
}
|
||||
|
||||
fn get_snapshots_count(store: &Arc<DataStore>, owner: Option<&Authid>) -> Result<Counts, Error> {
|
||||
ListAccessibleBackupGroups::new(Arc::clone(store), Default::default(), MAX_NAMESPACE_DEPTH, owner)?
|
||||
let root_ns = Default::default();
|
||||
ListAccessibleBackupGroups::new(Arc::clone(store), root_ns, MAX_NAMESPACE_DEPTH, owner)?
|
||||
.try_fold(Counts::default(), |mut counts, group| {
|
||||
let group = match group {
|
||||
Ok(group) => group,
|
||||
|
@ -21,7 +21,7 @@ pub struct ListAccessibleBackupGroups<'a> {
|
||||
ns_iter: ListNamespacesRecursive,
|
||||
}
|
||||
|
||||
impl <'a> ListAccessibleBackupGroups<'a> {
|
||||
impl<'a> ListAccessibleBackupGroups<'a> {
|
||||
// TODO: builder pattern
|
||||
|
||||
pub fn new(
|
||||
@ -41,7 +41,7 @@ impl <'a> ListAccessibleBackupGroups<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
impl <'a> Iterator for ListAccessibleBackupGroups<'a> {
|
||||
impl<'a> Iterator for ListAccessibleBackupGroups<'a> {
|
||||
type Item = Result<BackupGroup, Error>;
|
||||
|
||||
fn next(&mut self) -> Option<Self::Item> {
|
||||
|
Loading…
Reference in New Issue
Block a user