Housekeeping. Unit tests, coverage, formatter, linter. (#4)

Reviewed-on: #4
Co-authored-by: Drew Galbraith <drew@tiramisu.one>
Co-committed-by: Drew Galbraith <drew@tiramisu.one>
This commit is contained in:
Drew 2025-09-20 19:30:36 +00:00 committed by Drew
parent ef247e6e29
commit 8dae570755
4 changed files with 8 additions and 7 deletions

View file

@ -32,7 +32,7 @@ impl TaskModel {
title: &str,
description: Option<&str>,
) -> Result<TaskModel> {
if title.len() == 0 {
if title.is_empty() {
bail!("Title must not be empty");
}
@ -70,10 +70,10 @@ impl TaskModel {
)
.bind(&self.title)
.bind(&self.description)
.bind(&self.status)
.bind(self.status)
.bind(now)
.bind(&self.completed_at)
.bind(&self.id)
.bind(self.completed_at)
.bind(self.id)
.execute(pool)
.await?;