Skip to content

Commit

Permalink
refactor: Culling
Browse files Browse the repository at this point in the history
  • Loading branch information
sabihoshi committed Oct 14, 2022
1 parent 4146484 commit 2f0c5fb
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions HuTao.Culling/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,7 @@ public async Task CullMessagesInternalAsync(DateTimeOffset oldest)
var messageSet = _db!.Set<MessageLog>();
Log.Information("Getting messages to delete");
var messages = await messageSet
.Include(m => m.Embeds)
.Include(m => m.Components)
.Include(m => m.Attachments)
.Where(m => oldest > m.LogDate)
.Take(10000)
.OrderBy(m => m.LogDate)
.ToListAsync();
Log.Information("Culling messages older than {Oldest}, total {Count}", oldest, messages.Count);
Expand Down

0 comments on commit 2f0c5fb

Please sign in to comment.