Просмотр исходного кода

Avoid showing a broken image when there is no feed icon

Frédéric Guillot 5 лет назад
Родитель
Сommit
53cd369b05
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      template/templates/common/feed_list.html

+ 1 - 1
template/templates/common/feed_list.html

@@ -4,7 +4,7 @@
         <article class="item {{ if ne .ParsingErrorCount 0 }}feed-parsing-error{{ end }}">
             <div class="item-header" dir="auto">
                 <span class="item-title">
-                    {{ if .Icon }}
+                    {{ if and (.Icon) (gt .Icon.IconID 0) }}
                         <img src="{{ route "icon" "iconID" .Icon.IconID }}" width="16" height="16" loading="lazy" alt="{{ .Title }}">
                     {{ end }}
                     {{ if .Disabled }} 🚫 {{ end }}