From e174a22500100ebef4ca489b484b008350dfb0c7 Mon Sep 17 00:00:00 2001 From: Jordan Anderson Date: Wed, 20 Nov 2019 12:40:31 -0600 Subject: [PATCH] Hide credentials when submitting migration through API. Same fix, using form.CloneAddr instead of opts.CloneAddr. --- routers/api/v1/repo/repo.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/routers/api/v1/repo/repo.go b/routers/api/v1/repo/repo.go index e2a3bfc87301..cab0fc07e0e3 100644 --- a/routers/api/v1/repo/repo.go +++ b/routers/api/v1/repo/repo.go @@ -446,7 +446,7 @@ func Migrate(ctx *context.APIContext, form auth.MigrateRepoForm) { repo, err := models.CreateRepository(ctx.User, ctxUser, models.CreateRepoOptions{ Name: opts.RepoName, Description: opts.Description, - OriginalURL: opts.CloneAddr, + OriginalURL: form.CloneAddr, IsPrivate: opts.Private, IsMirror: opts.Mirror, Status: models.RepositoryBeingMigrated,