diff --git a/src/cmd/deploy.rs b/src/cmd/deploy.rs index b2f714c..90bb8fb 100644 --- a/src/cmd/deploy.rs +++ b/src/cmd/deploy.rs @@ -82,7 +82,6 @@ impl Profile { let mut max = 0; let res = match self.read_decrypted_mount_point() { Err(e) if e.kind() == ErrorKind::NotFound => { - // TODO: noswap mount tmpfs let support_ramfs = SupportedFilesystems::new().and_then(|fss| Ok(fss.is_supported("ramfs"))); if !support_ramfs? { diff --git a/src/helper/stored.rs b/src/helper/stored.rs index 021ecfb..5cb83bf 100644 --- a/src/helper/stored.rs +++ b/src/helper/stored.rs @@ -125,7 +125,6 @@ impl SecMap> { .collect(); SecMap::>(res) } - /// pass storageDirStore in pub fn renced(self, per_host_dir: PathBuf, host_pubkey: String) -> Self { let res = self .inner() @@ -134,15 +133,9 @@ impl SecMap> { let mut dir = per_host_dir.clone(); let sec_path = v; let sec_hash = sec_path - .read_buffer() - .and_then(|b| { - let mut hasher = blake3::Hasher::new(); - hasher.update(b.as_slice()); - hasher.update(host_pubkey.as_bytes()); - let hash_final = hasher.finalize(); - Ok(hash_final.to_string()) - }) - .expect("hash"); + .calc_hash(host_pubkey.clone()) + .expect("meow") + .to_string(); dir.push(sec_hash); let renced_in_per_host_dir = dir;