autopilot: continue threading context

Remove one context.TODO and add one more.
This commit is contained in:
Elle Mouton committed 2025-05-22 14:14:38 +02:00
1 parent 13fcb08794
commit 1c6c6436af
5 files changed
+17 -7

No files matched your search

+2 -2
View File
@@ -169,8 +169,8 @@ func betweennessCentrality(g *SimpleGraph, s int, centrality []float64) {
}
// Refresh recalculates and stores centrality values.
func (bc *BetweennessCentrality) Refresh(graph ChannelGraph) error {
ctx := context.TODO()
func (bc *BetweennessCentrality) Refresh(ctx context.Context,
graph ChannelGraph) error {
cache, err := NewSimpleGraph(ctx, graph)
if err != nil {