mirror of
https://github.com/go-gitea/gitea.git
synced 2026-11-22 01:45:12 +09:00
Backport #40450 by @lazerg After applying a patch in the web editor, Gitea redirected to `/src/branch/<branch>/__dummy_for_EditRepoFileForm.TreePath(Required)__`, which is a 404. The patch form only sends that placeholder `tree_path` to pass form validation, but the handler still used it as the redirect path. It now redirects to the branch root, like cherry-pick and revert do. Fixes: https://github.com/go-gitea/gitea/issues/40449 Assisted-by: Claude Code:claude-opus-5-5 Co-authored-by: Lazizbek Ergashev <lazerg2@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>