Validate expenses query.

This commit is contained in:
2026-09-21 20:39:20 +02:00
parent f65b0d0cdd
commit 54d8330fb1
3 changed files with 102 additions and 1 deletions
+2 -1
View File
@@ -13,7 +13,8 @@ pub fn create_router() -> axum::Router<PgPool> {
#[tracing::instrument(skip(pool))]
async fn get_expenses(State(pool): State<PgPool>) -> Result<Json<Vec<Expense>>, AppError> {
let rows = sqlx::query_as::<_, RecurringExpenseRow>(
let rows = sqlx::query_as!(
RecurringExpenseRow,
r#"
SELECT
id,