1
0
Fork 0
mirror of https://github.com/miniflux/v2.git synced 2025-07-27 17:28:38 +00:00

Fix template execution error (related to share feature)

This commit is contained in:
Frédéric Guillot 2020-03-18 17:55:15 -07:00
parent 59c8dac851
commit bd5aed7b90
2 changed files with 9 additions and 9 deletions

View file

@ -124,21 +124,21 @@
{{ if hasPrefix .MimeType "audio/" }}
<div class="enclosure-audio">
<audio controls preload="metadata">
<source src="{{ .URL }}" type="{{ .MimeType }}">
<source src="{{ .URL | safeURL }}" type="{{ .MimeType }}">
</audio>
</div>
{{ else if hasPrefix .MimeType "video/" }}
<div class="enclosure-video">
<video controls preload="metadata">
<source src="{{ .URL }}" type="{{ .MimeType }}">
<source src="{{ .URL | safeURL }}" type="{{ .MimeType }}">
</video>
</div>
{{ else if hasPrefix .MimeType "image/" }}
<div class="enclosure-image">
{{ if .user }}
{{ if $.user }}
<img src="{{ proxyURL .URL }}" title="{{ .URL }} ({{ .MimeType }})" loading="lazy" alt="{{ .URL }} ({{ .MimeType }})">
{{ else }}
<img src="{{ .URL }}" title="{{ .URL }} ({{ .MimeType }})" loading="lazy" alt="{{ .URL }} ({{ .MimeType }})">
<img src="{{ .URL | safeURL }}" title="{{ .URL }} ({{ .MimeType }})" loading="lazy" alt="{{ .URL }} ({{ .MimeType }})">
{{ end }}
</div>
{{ end }}