mirror of
https://github.com/isar/rusqlite.git
synced 2024-11-26 11:31:37 +08:00
code indent
This commit is contained in:
parent
d5bd7d9601
commit
13a32e4004
@ -918,7 +918,7 @@ mod test {
|
||||
CREATE TABLE foo(x INTEGER);
|
||||
INSERT INTO foo VALUES(42);
|
||||
END;";
|
||||
db.execute_batch(sql).unwrap();
|
||||
db.execute_batch(sql).unwrap();
|
||||
}
|
||||
|
||||
let path_string = path.to_str().unwrap();
|
||||
|
30
src/row.rs
30
src/row.rs
@ -30,21 +30,21 @@ impl<'stmt> Rows<'stmt> {
|
||||
pub fn next<'a>(&'a mut self) -> Option<Result<Row<'a, 'stmt>>> {
|
||||
self.stmt
|
||||
.and_then(|stmt| match stmt.step() {
|
||||
Ok(true) => {
|
||||
Some(Ok(Row {
|
||||
stmt: stmt,
|
||||
phantom: PhantomData,
|
||||
}))
|
||||
}
|
||||
Ok(false) => {
|
||||
self.reset();
|
||||
None
|
||||
}
|
||||
Err(err) => {
|
||||
self.reset();
|
||||
Some(Err(err))
|
||||
}
|
||||
})
|
||||
Ok(true) => {
|
||||
Some(Ok(Row {
|
||||
stmt: stmt,
|
||||
phantom: PhantomData,
|
||||
}))
|
||||
}
|
||||
Ok(false) => {
|
||||
self.reset();
|
||||
None
|
||||
}
|
||||
Err(err) => {
|
||||
self.reset();
|
||||
Some(Err(err))
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user