mirror of
				https://github.com/go-gitea/gitea
				synced 2025-11-03 21:08:25 +00:00 
			
		
		
		
	Fix nil pointer in default issue mail template (#11862)
* Fix nil pointer in default issue mail template
Fix: template: issue/default:20:17: executing "issue/default" at <.Comment.Type>: nil pointer evaluating interface {}.Type
Introduced in #11167
* another one
Co-authored-by: zeripath <art27@cantab.net>
			
			
This commit is contained in:
		@@ -17,7 +17,7 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
<body>
 | 
					<body>
 | 
				
			||||||
	{{if .IsMention}}<p><b>@{{.Doer.Name}}</b> mentioned you:</p>{{end}}
 | 
						{{if .IsMention}}<p><b>@{{.Doer.Name}}</b> mentioned you:</p>{{end}}
 | 
				
			||||||
	{{if eq .Comment.Type 29}}
 | 
						{{if eq .ActionName "push"}}
 | 
				
			||||||
		<p>
 | 
							<p>
 | 
				
			||||||
			<b>{{.Doer.Name}}</b>  
 | 
								<b>{{.Doer.Name}}</b>  
 | 
				
			||||||
			{{if .Comment.IsForcePush}}
 | 
								{{if .Comment.IsForcePush}}
 | 
				
			||||||
@@ -66,7 +66,7 @@
 | 
				
			|||||||
				<div>{{.RenderedContent | Safe}}</div>
 | 
									<div>{{.RenderedContent | Safe}}</div>
 | 
				
			||||||
			</div>
 | 
								</div>
 | 
				
			||||||
		{{end -}}
 | 
							{{end -}}
 | 
				
			||||||
		{{if eq .Comment.Type 29}}
 | 
							{{if eq .ActionName "push"}}
 | 
				
			||||||
			{{ $r:= List .Comment.Commits}}
 | 
								{{ $r:= List .Comment.Commits}}
 | 
				
			||||||
			<ul>
 | 
								<ul>
 | 
				
			||||||
			{{range $r}}
 | 
								{{range $r}}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user