fix for rusqlite Result api

This commit is contained in:
Conrad Dean 2019-07-22 08:58:19 -04:00
parent f4002f34f4
commit 76ae972e2e
2 changed files with 2 additions and 2 deletions

View file

@ -67,7 +67,7 @@ impl SyncMetadata {
tx.query_row(
"SELECT value FROM tolstoy_metadata WHERE key = ?",
&[&schema::REMOTE_HEAD_KEY], |r| {
let bytes: Vec<u8> = r.get(0);
let bytes: Vec<u8> = r.get(0).unwrap();
Uuid::from_bytes(bytes.as_slice())
}
)?.map_err(|e| e.into())

View file

@ -83,7 +83,7 @@ impl TxMapper {
)?;
let results = stmt.query_and_then(&[&tx], |r| -> Result<Uuid>{
let bytes: Vec<u8> = r.get(0);
let bytes: Vec<u8> = r.get(0).unwrap();
Uuid::from_bytes(bytes.as_slice()).map_err(|e| e.into())
})?;