From 3a55b35ecc1dfbe1d340231db3cbe24f8c5112d4 Mon Sep 17 00:00:00 2001 From: ahmed Date: Fri, 31 Jan 2025 10:48:29 -0500 Subject: [PATCH] update handleRateLimit signature --- pkg/sources/github/connector_token.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/sources/github/connector_token.go b/pkg/sources/github/connector_token.go index 88ef8f8f1ec0..469f50b98c2f 100644 --- a/pkg/sources/github/connector_token.go +++ b/pkg/sources/github/connector_token.go @@ -17,14 +17,14 @@ type tokenConnector struct { apiClient *github.Client token string isGitHubEnterprise bool - handleRateLimit func(context.Context, error) bool + handleRateLimit func(context.Context, error, ...errorReporter) bool user string userMu sync.Mutex } var _ connector = (*tokenConnector)(nil) -func newTokenConnector(apiEndpoint string, token string, handleRateLimit func(context.Context, error) bool) (*tokenConnector, error) { +func newTokenConnector(apiEndpoint string, token string, handleRateLimit func(context.Context, error, ...errorReporter) bool) (*tokenConnector, error) { const httpTimeoutSeconds = 60 httpClient := common.RetryableHTTPClientTimeout(int64(httpTimeoutSeconds)) tokenSource := oauth2.StaticTokenSource(&oauth2.Token{AccessToken: token})