diff options
author | Matthias Loibl <mail@matthiasloibl.com> | 2016-11-08 18:28:00 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-11-08 18:27:59 +0100 |
commit | 45c4539c6168aa248e425033731ab7a9a21c5958 (patch) | |
tree | 7235c6a9dc9d75a092d7d03a28d6ad790e47136b /routers | |
parent | f6d53ecbc1a1f1475d2ed6753176db43278dfd7f (diff) | |
parent | 01c5233b53d931996844716dfe80511fd1f9abb5 (diff) | |
download | gitea-45c4539c6168aa248e425033731ab7a9a21c5958.tar.gz gitea-45c4539c6168aa248e425033731ab7a9a21c5958.zip |
Merge pull request #17 from LefsFlarey/issue/3666
Fixed 404 caused by unexpected question mark
Diffstat (limited to 'routers')
-rw-r--r-- | routers/repo/editor.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/repo/editor.go b/routers/repo/editor.go index 26f74ef3d0..b4aac27bea 100644 --- a/routers/repo/editor.go +++ b/routers/repo/editor.go @@ -264,7 +264,7 @@ func editFilePost(ctx *context.Context, form auth.EditRepoFileForm, isNewFile bo return } - ctx.Redirect(ctx.Repo.RepoLink + "/src/" + branchName + "/" + form.TreePath) + ctx.Redirect(ctx.Repo.RepoLink + "/src/" + branchName + "/" + strings.NewReplacer("%", "%25", "#", "%23", " ", "%20", "?", "%3F").Replace(form.TreePath)) } func EditFilePost(ctx *context.Context, form auth.EditRepoFileForm) { |