base HTML: fix nil on emails without a text part

P.a. to 50e131244a which solved
https://todo.sr.ht/~emersion/alps/100

Closes: https://todo.sr.ht/~emersion/alps/102
This commit is contained in:
наб 2020-07-13 15:48:31 +02:00 committed by Simon Ser
parent 92b3016196
commit d60aca0e5c
No known key found for this signature in database
GPG key ID: 0FDE7BE0E88F5E48

View file

@ -27,7 +27,7 @@
<ul> <ul>
{{range .Messages}} {{range .Messages}}
<li> <li>
<a href="{{.TextPart.URL false}}"> <a href="{{if .TextPart}}{{.TextPart.URL false}}{{else}}{{.URL}}{{end}}">
{{if .Envelope.Subject}} {{if .Envelope.Subject}}
{{.Envelope.Subject}} {{.Envelope.Subject}}
{{else}} {{else}}