diff --git a/modules/context/repo.go b/modules/context/repo.go index f3ae33cb5..53dbaa3bc 100644 --- a/modules/context/repo.go +++ b/modules/context/repo.go @@ -619,8 +619,8 @@ func RepoRefByType(refType RepoRefType) macaron.Handler { // redirect from old URL scheme to new URL scheme ctx.Redirect(path.Join( setting.AppSubURL, - strings.TrimSuffix(ctx.Req.URL.String(), ctx.Params("*")), - ctx.Repo.BranchNameSubURL(), + path.Dir(ctx.Req.URL.String()), + strings.NewReplacer("%", "%25", "#", "%23", " ", "%20", "?", "%3F").Replace(ctx.Repo.BranchNameSubURL()), ctx.Repo.TreePath)) return } diff --git a/templates/repo/activity.tmpl b/templates/repo/activity.tmpl index f5454afb9..2adc8e44c 100644 --- a/templates/repo/activity.tmpl +++ b/templates/repo/activity.tmpl @@ -84,7 +84,7 @@
{{$.i18n.Tr "repo.branch.deleted_by" .DeletedBranch.DeletedBy.Name}} {{TimeSinceUnix .DeletedBranch.DeletedUnix $.i18n.Lang}}
{{else}} - {{.Name}} + {{.Name}}{{$.i18n.Tr "org.repo_updated"}} {{TimeSince .Commit.Committer.When $.i18n.Lang}}