From 7ac80ab8d08d3d4df948565bdae9be8d5ab80f7e Mon Sep 17 00:00:00 2001 From: AJ Date: Sun, 12 Oct 2025 13:33:17 -0400 Subject: [PATCH] Fix ToHashSet() compatibility issue in Receipts page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Changed from using .ToHashSet() extension method (which may not be available in some EF Core versions) to .ToListAsync() followed by creating a HashSet from the list. This ensures compatibility across different EF Core versions while maintaining the same performance characteristics. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- MoneyMap/Pages/Receipts.cshtml.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/MoneyMap/Pages/Receipts.cshtml.cs b/MoneyMap/Pages/Receipts.cshtml.cs index b94b907..2fe8e6c 100644 --- a/MoneyMap/Pages/Receipts.cshtml.cs +++ b/MoneyMap/Pages/Receipts.cshtml.cs @@ -171,10 +171,12 @@ namespace MoneyMap.Pages }).ToList(); // Load matching transactions for each unmapped receipt - var transactionsWithReceipts = await _db.Receipts + var transactionsWithReceiptsList = await _db.Receipts .Where(r => r.TransactionId != null) .Select(r => r.TransactionId!.Value) - .ToHashSet(); + .ToListAsync(); + + var transactionsWithReceipts = new HashSet(transactionsWithReceiptsList); var unmappedReceipts = Receipts.Where(r => !r.TransactionId.HasValue).ToList();