Skip to content

Commit 43d7d7e

Browse files
gernotegerzeripath
authored andcommitted
Set the base url when migrating from Gitlab using access token or username without password (go-gitea#11852)
Backport go-gitea#11852 When migrating from gitlab, set the baseUrl in NewGitlabDownloader when using an access token or username without password Fix go-gitea#11851
1 parent df13fc8 commit 43d7d7e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/migrations/gitlab.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ func NewGitlabDownloader(baseURL, repoPath, username, password string) *GitlabDo
9090
var err error
9191
if username != "" {
9292
if password == "" {
93-
gitlabClient, err = gitlab.NewClient(username)
93+
gitlabClient, err = gitlab.NewClient(username, gitlab.WithBaseURL(baseURL))
9494
} else {
9595
gitlabClient, err = gitlab.NewBasicAuthClient(username, password, gitlab.WithBaseURL(baseURL))
9696
}

0 commit comments

Comments
 (0)