diff options
Diffstat (limited to 'bridge/gitlab')
-rw-r--r-- | bridge/gitlab/gitlab.go | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/bridge/gitlab/gitlab.go b/bridge/gitlab/gitlab.go index d854f2f1..3625a9bb 100644 --- a/bridge/gitlab/gitlab.go +++ b/bridge/gitlab/gitlab.go @@ -1,7 +1,6 @@ package gitlab import ( - "net/http" "time" "github.com/xanzy/go-gitlab" @@ -48,12 +47,9 @@ func (Gitlab) NewExporter() core.Exporter { } func buildClient(baseURL string, token *auth.Token) (*gitlab.Client, error) { - httpClient := &http.Client{ - Timeout: defaultTimeout, - } - - gitlabClient := gitlab.NewClient(httpClient, token.Value) - err := gitlabClient.SetBaseURL(baseURL) + gitlabClient, err := gitlab.NewClient(token.Value, + gitlab.WithBaseURL(baseURL), + ) if err != nil { return nil, err } |