Skip to content

Commit c4aed78

Browse files
committed
f Remove TODO for now
1 parent 542e7c0 commit c4aed78

File tree

1 file changed

+0
-26
lines changed

1 file changed

+0
-26
lines changed

src/io/mod.rs

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -71,29 +71,3 @@ pub trait TransactionalWrite: Write {
7171
/// Persist the previously made changes.
7272
fn commit(&mut self) -> std::io::Result<()>;
7373
}
74-
75-
// TODO: Use this generic impl once we have Node<K>
76-
//impl<T> KVStorePersister for T
77-
//where T: KVStore
78-
//{
79-
// fn persist<W: Writeable>(&self, prefixed_key: &str, object: &W) -> lightning::io::Result<()> {
80-
// let msg = format!("Could not persist data for key {}.", prefixed_key);
81-
// let dest_file = PathBuf::from_str(prefixed_key).map_err(|_| {
82-
// lightning::io::Error::new(lightning::io::ErrorKind::InvalidInput, msg.clone())
83-
// })?;
84-
//
85-
// let parent_directory = dest_file.parent().ok_or(lightning::io::Error::new(
86-
// lightning::io::ErrorKind::InvalidInput,
87-
// msg.clone(),
88-
// ))?;
89-
// let namespace = parent_directory.display().to_string();
90-
//
91-
// let dest_without_namespace = dest_file
92-
// .strip_prefix(&namespace)
93-
// .map_err(|_| lightning::io::Error::new(lightning::io::ErrorKind::InvalidInput, msg))?;
94-
// let key = dest_without_namespace.display().to_string();
95-
// let mut writer = self.write(&namespace, &key)?;
96-
// object.write(&mut writer)?;
97-
// Ok(writer.commit()?)
98-
// }
99-
//}

0 commit comments

Comments
 (0)