From 3679011b67370192bbc3778384264bd7177fb644 Mon Sep 17 00:00:00 2001 From: Ted Wollman <25165500+TheTedder@users.noreply.github.com> Date: Wed, 16 Oct 2024 22:02:02 -0400 Subject: [PATCH] Listen to the correct event for updating models. (#252) --- LeaderboardBackend/Models/Entities/ApplicationContext.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LeaderboardBackend/Models/Entities/ApplicationContext.cs b/LeaderboardBackend/Models/Entities/ApplicationContext.cs index bfccd3c1..654529ec 100644 --- a/LeaderboardBackend/Models/Entities/ApplicationContext.cs +++ b/LeaderboardBackend/Models/Entities/ApplicationContext.cs @@ -41,7 +41,7 @@ public ApplicationContext(DbContextOptions options, IClock c { _clock = clock; ChangeTracker.Tracked += AddCreationTimestamp; - ChangeTracker.Tracked += SetUpdateTimestamp; + ChangeTracker.StateChanged += SetUpdateTimestamp; } public DbSet AccountRecoveries { get; set; } = null!;