share a bunch of the database load code in timeline cache, don't clear timelines on relationship change

This commit is contained in:
kim 2025-04-08 15:19:36 +01:00
commit b04b4f8516
5 changed files with 148 additions and 172 deletions

View file

@ -199,9 +199,6 @@ func (p *Processor) getStatusTimeline(
apiStatuses, lo, hi, err = timelinepkg.LoadStatusTimeline(ctx,
page,
loadPage,
func(ids []string) ([]*gtsmodel.Status, error) {
return p.state.DB.GetStatusesByIDs(ctx, ids)
},
filter,
prepare,
)