Skip to content

Commit 9f98839

Browse files
committed
remove treepath="patch" elsewhere too
Signed-off-by: Andrew Thornton <[email protected]>
1 parent f370b9b commit 9f98839

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

routers/web/repo/cherry_pick.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ func CherryPick(ctx *context.Context) {
5050
ctx.Data["RequireHighlightJS"] = true
5151

5252
canCommit := renderCommitRights(ctx)
53-
ctx.Data["TreePath"] = "patch"
53+
ctx.Data["TreePath"] = ""
5454

5555
if canCommit {
5656
ctx.Data["commit_choice"] = frmCommitChoiceDirect

routers/web/repo/patch.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ func NewDiffPatchPost(ctx *context.Context) {
5555
branchName = form.NewBranchName
5656
}
5757
ctx.Data["RequireHighlightJS"] = true
58-
ctx.Data["TreePath"] = "patch"
58+
ctx.Data["TreePath"] = ""
5959
ctx.Data["BranchLink"] = ctx.Repo.RepoLink + "/src/" + ctx.Repo.BranchNameSubURL()
6060
ctx.Data["FileContent"] = form.Content
6161
ctx.Data["commit_summary"] = form.CommitSummary

templates/repo/editor/patch.tmpl

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<div class="divider">:</div>
1616
<a class="section" href="{{$.BranchLink}}">{{.BranchName}}</a>
1717
<span>{{.i18n.Tr "repo.editor.or"}} <a href="{{$.BranchLink}}">{{.i18n.Tr "repo.editor.cancel_lower"}}</a></span>
18-
<input type="hidden" id="tree_path" name="tree_path" value="patch" required>
18+
<input type="hidden" id="tree_path" name="tree_path" value="" required>
1919
<input id="file-name" type="hidden" value="diff.patch">
2020
</div>
2121
</div>

0 commit comments

Comments
 (0)