aboutsummaryrefslogtreecommitdiff
path: root/src/block/layout.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/block/layout.rs')
-rw-r--r--src/block/layout.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/block/layout.rs b/src/block/layout.rs
index 8098654f..e32ef785 100644
--- a/src/block/layout.rs
+++ b/src/block/layout.rs
@@ -252,6 +252,14 @@ impl DataLayout {
path.push(hex::encode(&hash.as_slice()[1..2]));
path
}
+
+ pub(crate) fn without_secondary_locations(&self) -> Self {
+ Self {
+ data_dirs: self.data_dirs.clone(),
+ part_prim: self.part_prim.clone(),
+ part_sec: self.part_sec.iter().map(|_| vec![]).collect::<Vec<_>>(),
+ }
+ }
}
impl InitialFormat for DataLayout {