Migrated database changes after refactoring the Notification model

This commit is contained in:
Khwezi Mngoma
2026-05-10 15:27:26 +02:00
parent 394429677e
commit e8e9a85c57
20 changed files with 244 additions and 777 deletions
@@ -17,6 +17,12 @@ public class UpdateNotificationCommandHandler(IDbContextFactory<ShopDbContext> c
notification.Processed = request.Processed;
if (request.HasError)
{
notification.HasError = request.HasError;
notification.Errors = request.Errors;
}
return await context.SaveChangesAsync(cancellationToken) > 0
? Result.Ok()
: Result.Fail(new Error($"Failed to update notification with id {request.NotificationId}."));