Remove redundant copy from RocksDB get_cf() wrapper (#17529)
This commit is contained in:
parent
8eab0e8602
commit
983828a2a9
|
@ -363,7 +363,7 @@ impl Rocks {
|
|||
}
|
||||
|
||||
fn get_cf(&self, cf: &ColumnFamily, key: &[u8]) -> Result<Option<Vec<u8>>> {
|
||||
let opt = self.0.get_cf(cf, key)?.map(|db_vec| db_vec.to_vec());
|
||||
let opt = self.0.get_cf(cf, key)?;
|
||||
Ok(opt)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue