1
0
mirror of https://github.com/RaidMax/IW4M-Admin.git synced 2025-06-10 15:20:48 -05:00

small startup performance optimization

This commit is contained in:
RaidMax
2022-01-28 09:35:01 -06:00
parent b4476f9e23
commit 1c89b00907
28 changed files with 112 additions and 67 deletions

View File

@ -355,7 +355,7 @@ namespace IW4MAdmin
try
{
var factory = _serviceProvider.GetRequiredService<IDatabaseContextFactory>();
await using var context = factory.CreateContext();
await using var context = factory.CreateContext(enableTracking: false);
var messageCount = await context.InboxMessages
.CountAsync(msg => msg.DestinationClientId == E.Origin.ClientId && !msg.IsDelivered);