Make Db::drop_tree parameters match open_tree parameters.
Because the new bound AsRef<[u8]> covers the previous type &[u8], this should
not be a breaking change.
@@ -158,7 +158,8 @@ impl Db {
}
/// Remove a disk-backed collection.
- pub fn drop_tree(&self, name: &[u8]) -> Result<bool> {
+ pub fn drop_tree<V: AsRef<[u8]>>(&self, name: V) -> Result<bool> {
+ let name = name.as_ref();
if name == DEFAULT_TREE_ID {
return Err(Error::Unsupported(
"cannot remove the core structures".into(),
