From fea0f48cecb3cf75e18be65eb655c5886356409b Mon Sep 17 00:00:00 2001 From: Knee Cola Date: Mon, 29 Dec 2025 21:11:07 +0100 Subject: [PATCH] fix: include tenantEmail and tenantEmailStatus in fetchAllLocations projection MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Added tenantEmail and tenantEmailStatus fields to the MongoDB projection in fetchAllLocations() so LocationCard can display email status indicators. Previously these fields were always undefined in LocationCard because they weren't included in the aggregation pipeline's $project stage. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 --- web-app/app/lib/actions/locationActions.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/web-app/app/lib/actions/locationActions.ts b/web-app/app/lib/actions/locationActions.ts index 489b787..12068c1 100644 --- a/web-app/app/lib/actions/locationActions.ts +++ b/web-app/app/lib/actions/locationActions.ts @@ -446,6 +446,8 @@ export const fetchAllLocations = withUser(async (user:AuthenticatedUser, year:nu "bills.payedAmount": 1, "bills.proofOfPayment.uploadedAt": 1, "seenByTenantAt": 1, + "tenantEmail": 1, + "tenantEmailStatus": 1, // "bills.attachment": 0, // "bills.notes": 0, // "bills.hub3aText": 1,