optimize get w/ zero-copy ref handle

Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
Jason Volk 2024-07-02 05:56:10 +00:00
parent 0522fe7d92
commit ee64fb149c
11 changed files with 46 additions and 16 deletions

View file

@ -226,7 +226,7 @@ lasttimelinecount_cache: {lasttimelinecount_cache} / {max_lasttimelinecount_cach
self.global.insert(b"keypair", &keypair)?;
Ok::<_, Error>(keypair)
},
Ok,
|val| Ok(val.to_vec()),
)?;
let mut parts = keypair_bytes.splitn(2, |&b| b == 0xFF);