diff --git a/hub/route/groups.go b/hub/route/groups.go index e877bfd0..13133e9c 100644 --- a/hub/route/groups.go +++ b/hub/route/groups.go @@ -64,7 +64,7 @@ func getGroupDelay(w http.ResponseWriter, r *http.Request) { return } - ctx, cancel := context.WithTimeout(context.Background(), time.Millisecond*time.Duration(timeout)) + ctx, cancel := context.WithTimeout(r.Context(), time.Millisecond*time.Duration(timeout)) defer cancel() dm, err := group.URLTest(ctx, url)