help compiler with an annotation on the outside of an expression instead of halfway through the middle of an expression
This commit is contained in:
parent
76ae972e2e
commit
4e9d6b3f58
1 changed files with 4 additions and 4 deletions
|
@ -143,17 +143,17 @@ impl SyncMetadata {
|
|||
}
|
||||
|
||||
pub fn is_tx_empty(db_tx: &rusqlite::Transaction, tx_id: Entid) -> Result<bool> {
|
||||
let count = db_tx.query_row("SELECT count(rowid) FROM timelined_transactions WHERE timeline = 0 AND tx = ? AND e != ?", &[&tx_id, &tx_id], |row| -> Result<i64> {
|
||||
let count: i64 = db_tx.query_row("SELECT count(rowid) FROM timelined_transactions WHERE timeline = 0 AND tx = ? AND e != ?", &[&tx_id, &tx_id], |row| {
|
||||
Ok(row.get(0)?)
|
||||
})?;
|
||||
Ok(count? == 0)
|
||||
Ok(count == 0)
|
||||
}
|
||||
|
||||
pub fn has_entity_assertions_in_tx(db_tx: &rusqlite::Transaction, e: Entid, tx_id: Entid) -> Result<bool> {
|
||||
let count = db_tx.query_row("SELECT count(rowid) FROM timelined_transactions WHERE timeline = 0 AND tx = ? AND e = ?", &[&tx_id, &e], |row| -> Result<i64> {
|
||||
let count: i64 = db_tx.query_row("SELECT count(rowid) FROM timelined_transactions WHERE timeline = 0 AND tx = ? AND e = ?", &[&tx_id, &e], |row| {
|
||||
Ok(row.get(0)?)
|
||||
})?;
|
||||
Ok(count? > 0)
|
||||
Ok(count > 0)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue