From 7dc03f3bc0670425dfa461fba59349e726cbe775 Mon Sep 17 00:00:00 2001 From: Chris Chen Date: Wed, 24 Jun 2026 11:17:19 -0700 Subject: [PATCH] docs(attendance): explain SetCountsAsync divergence from ExecuteUpdate path --- API/ROLAC.API/Services/MealAttendanceService.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/API/ROLAC.API/Services/MealAttendanceService.cs b/API/ROLAC.API/Services/MealAttendanceService.cs index f986b31..c273838 100644 --- a/API/ROLAC.API/Services/MealAttendanceService.cs +++ b/API/ROLAC.API/Services/MealAttendanceService.cs @@ -84,6 +84,8 @@ public class MealAttendanceService : IMealAttendanceService public async Task SetCountsAsync(DateOnly date, int adult, int youth, int kid) { + // Single-editor back-office path, so a tracked load + SaveChanges is fine here; no need for the + // race-safe EnsureRowAsync + ExecuteUpdateAsync pattern, which the EF InMemory test provider can't run. var row = await _db.MealAttendances.FirstOrDefaultAsync(a => a.AttendanceDate == date); if (row is null) {