(&self)
| 70 | } |
| 71 | |
| 72 | pub async fn begin(&self) -> Result<SqliteTransaction<'_>, DatabaseError> { |
| 73 | self.pool |
| 74 | .begin() |
| 75 | .await |
| 76 | .map_err(|e| DatabaseError::TransactionError(e.to_string())) |
| 77 | } |
| 78 | |
| 79 | pub async fn transaction<F, T, Fut>(&self, f: F) -> Result<T, DatabaseError> |
| 80 | where |