small fixes

This commit is contained in:
teldra 2022-04-03 22:01:16 +02:00
parent e1a31f5046
commit 7b3ae2faad
1 changed files with 2 additions and 4 deletions

View File

@ -37,13 +37,11 @@
<guid>{{ .Permalink }}</guid>
<description>
{{ $img := index (.Resources.ByType "image") 0 }}
{{ printf "\<![CDATA\[" | safeHTML }}
{{ with $img }}
{{ $img := .Resize "640x" }}
{{ printf "<img src=\"%s\" width=\"%d\" height=\"%d\"/>]]>" $img.Permalink $img.Width $img.Height | safeHTML }}
{{ printf "<![CDATA[<img src=\"%s\" width=\"%d\" height=\"%d\"/>]]>" $img.Permalink $img.Width $img.Height | safeHTML }}
{{ end }}
{{ .Content | html }}
{{ printf "]]>" $img.Permalink $img.Width $img.Height | safeHTML }}
{{ printf "<![CDATA[%s]]>" .Content | safeHTML }}
</description>
</item>