File tree Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -689,6 +689,11 @@ func ActionIcon(opType models.ActionType) string {
689
689
// ActionContent2Commits converts action content to push commits
690
690
func ActionContent2Commits (act Actioner ) * repository.PushCommits {
691
691
push := repository .NewPushCommits ()
692
+
693
+ if act == nil || act .GetContent () == "" {
694
+ return push
695
+ }
696
+
692
697
if err := json .Unmarshal ([]byte (act .GetContent ()), push ); err != nil {
693
698
log .Error ("json.Unmarshal:\n %s\n ERROR: %v" , act .GetContent (), err )
694
699
}
Original file line number Diff line number Diff line change 96
96
<span class="text truncate issue title">{{index .GetIssueInfos 1 | RenderEmoji}}</span>
97
97
{{else if or (eq .GetOpType 10) (eq .GetOpType 21) (eq .GetOpType 22) (eq .GetOpType 23)}}
98
98
<a href="{{.GetCommentLink}}" class="text truncate issue title">{{.GetIssueTitle | RenderEmoji}}</a>
99
- <p class="text light grey">{{index .GetIssueInfos 1 | RenderEmoji}}</p>
99
+ {{$comment := index .GetIssueInfos 1}}
100
+ {{if gt (len $comment) 0}}<p class="text light grey">{{$comment | RenderEmoji}}</p>{{end}}
100
101
{{else if eq .GetOpType 11}}
101
102
<p class="text light grey">{{index .GetIssueInfos 1}}</p>
102
103
{{else if or (eq .GetOpType 12) (eq .GetOpType 13) (eq .GetOpType 14) (eq .GetOpType 15)}}
You can’t perform that action at this time.
0 commit comments