Standardized the upsert and delete pattern across the repo.

This commit is contained in:
2026-10-09 15:09:04 +02:00
parent 4a84c8330a
commit 66984567f8
30 changed files with 776 additions and 386 deletions
+2 -2
View File
@@ -1,6 +1,6 @@
use uuid::Uuid;
use super::{QueryConversionError, RepositoryError, dtos::Upserted};
use super::{QueryConversionError, RepositoryError, dtos::Upsert};
use crate::{
database::{Constraint, DatabaseError, dtos::UserAppRow, user_apps as db},
domain::UserApp,
@@ -59,7 +59,7 @@ where
Ok(owner)
}
pub async fn upsert<'e, E>(executor: E, app: UserApp) -> Result<Upserted<UserApp>, RepositoryError>
pub async fn upsert<'e, E>(executor: E, app: UserApp) -> Result<Upsert<UserApp>, RepositoryError>
where
E: sqlx::Executor<'e, Database = sqlx::Postgres>,
{