aboutsummaryrefslogtreecommitdiff
path: root/routes/repo/issue.go
diff options
context:
space:
mode:
Diffstat (limited to 'routes/repo/issue.go')
-rw-r--r--routes/repo/issue.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/routes/repo/issue.go b/routes/repo/issue.go
index 41d0df1f..70535b2e 100644
--- a/routes/repo/issue.go
+++ b/routes/repo/issue.go
@@ -23,6 +23,7 @@ import (
"github.com/gogits/gogs/pkg/form"
"github.com/gogits/gogs/pkg/markup"
"github.com/gogits/gogs/pkg/setting"
+ "github.com/gogits/gogs/pkg/template"
"github.com/gogits/gogs/pkg/tool"
)
@@ -657,7 +658,7 @@ func viewIssue(c *context.Context, isPullList bool) {
c.Repo.IsWriter() && c.Repo.GitRepo.IsBranchExist(pull.HeadBranch) &&
!branchProtected
- deleteBranchUrl := c.Repo.RepoLink + "/branches/delete/" + pull.HeadBranch
+ deleteBranchUrl := template.EscapePound(c.Repo.RepoLink + "/branches/delete/" + pull.HeadBranch)
c.Data["DeleteBranchLink"] = fmt.Sprintf("%s?commit=%s&redirect_to=%s", deleteBranchUrl, pull.MergedCommitID, c.Data["Link"])
}