aboutsummaryrefslogtreecommitdiff
path: root/routers
diff options
context:
space:
mode:
Diffstat (limited to 'routers')
-rw-r--r--routers/api/v1/repo/repo.go2
-rw-r--r--routers/repo/http.go1
-rw-r--r--routers/repo/repo.go4
3 files changed, 3 insertions, 4 deletions
diff --git a/routers/api/v1/repo/repo.go b/routers/api/v1/repo/repo.go
index d7109f78..e0f62baf 100644
--- a/routers/api/v1/repo/repo.go
+++ b/routers/api/v1/repo/repo.go
@@ -270,7 +270,7 @@ func Migrate(ctx *context.APIContext, f form.MigrateRepo) {
log.Error(4, "DeleteRepository: %v", errDelete)
}
}
- ctx.Error(500, "MigrateRepository", models.HandleCloneUserCredentials(err.Error(), true))
+ ctx.Error(500, "MigrateRepository", models.HandleMirrorCredentials(err.Error(), true))
return
}
diff --git a/routers/repo/http.go b/routers/repo/http.go
index 7c1f690e..b3b6aa1a 100644
--- a/routers/repo/http.go
+++ b/routers/repo/http.go
@@ -111,7 +111,6 @@ func HTTPContexter() macaron.Handler {
askCredentials(c, http.StatusUnauthorized, "")
return
}
- fmt.Println(authUsername, authPassword)
authUser, err := models.UserSignIn(authUsername, authPassword)
if err != nil && !errors.IsUserNotExist(err) {
diff --git a/routers/repo/repo.go b/routers/repo/repo.go
index 3626ac49..a3e5291d 100644
--- a/routers/repo/repo.go
+++ b/routers/repo/repo.go
@@ -217,11 +217,11 @@ func MigratePost(ctx *context.Context, f form.MigrateRepo) {
if strings.Contains(err.Error(), "Authentication failed") ||
strings.Contains(err.Error(), "could not read Username") {
ctx.Data["Err_Auth"] = true
- ctx.RenderWithErr(ctx.Tr("form.auth_failed", models.HandleCloneUserCredentials(err.Error(), true)), MIGRATE, &f)
+ ctx.RenderWithErr(ctx.Tr("form.auth_failed", models.HandleMirrorCredentials(err.Error(), true)), MIGRATE, &f)
return
} else if strings.Contains(err.Error(), "fatal:") {
ctx.Data["Err_CloneAddr"] = true
- ctx.RenderWithErr(ctx.Tr("repo.migrate.failed", models.HandleCloneUserCredentials(err.Error(), true)), MIGRATE, &f)
+ ctx.RenderWithErr(ctx.Tr("repo.migrate.failed", models.HandleMirrorCredentials(err.Error(), true)), MIGRATE, &f)
return
}