|
|
@ -7,6 +7,7 @@ package models |
|
|
|
import ( |
|
|
|
import ( |
|
|
|
"encoding/json" |
|
|
|
"encoding/json" |
|
|
|
"fmt" |
|
|
|
"fmt" |
|
|
|
|
|
|
|
"html" |
|
|
|
"path" |
|
|
|
"path" |
|
|
|
"regexp" |
|
|
|
"regexp" |
|
|
|
"strconv" |
|
|
|
"strconv" |
|
|
@ -532,7 +533,7 @@ func UpdateIssuesCommit(doer *User, repo *Repository, commits []*PushCommit, bra |
|
|
|
} |
|
|
|
} |
|
|
|
refMarked[issue.ID] = true |
|
|
|
refMarked[issue.ID] = true |
|
|
|
|
|
|
|
|
|
|
|
message := fmt.Sprintf(`<a href="%s/commit/%s">%s</a>`, repo.Link(), c.Sha1, c.Message) |
|
|
|
message := fmt.Sprintf(`<a href="%s/commit/%s">%s</a>`, repo.Link(), c.Sha1, html.EscapeString(c.Message)) |
|
|
|
if err = CreateRefComment(doer, repo, issue, message, c.Sha1); err != nil { |
|
|
|
if err = CreateRefComment(doer, repo, issue, message, c.Sha1); err != nil { |
|
|
|
return err |
|
|
|
return err |
|
|
|
} |
|
|
|
} |
|
|
|