♻️ Refactor activitypub content storage

This commit is contained in:
2025-12-30 23:37:57 +08:00
parent 8dc01c8a85
commit 6aa6833163
26 changed files with 3339 additions and 919 deletions

View File

@@ -556,9 +556,12 @@ public class PublisherService(
.ToListAsync();
// Group stats by publisher id
var postIdToPublisher = postsInPeriod.ToDictionary(p => p.Id, p => p.PublisherId);
var postIdToPublisher = postsInPeriod
.Where(p => p.PublisherId.HasValue)
.ToDictionary(p => p.Id, p => p.PublisherId!.Value);
var publisherStats = postsInPeriod
.GroupBy(p => p.PublisherId)
.Where(p => p.PublisherId.HasValue)
.GroupBy(p => p.PublisherId!.Value)
.ToDictionary(g => g.Key,
g => new
{