Show feeds without webhooks

This commit is contained in:
2022-12-21 01:37:40 +01:00
parent c68bb6e12b
commit 8e88fb7f65
2 changed files with 13 additions and 1 deletions

View File

@ -379,7 +379,7 @@ def make_context_index(request) -> dict:
hook = reader.get_tag(feed.url, "webhook")
feed_list.append({"feed": feed, "webhook": hook})
except TagNotFoundError:
broken_feeds.append({"feed": feed, "webhook": None})
broken_feeds.append(feed)
continue
# Sort feed_list by when the feed was added.

View File

@ -45,5 +45,17 @@
No feeds yet. Add one <a class="text-muted" href="/add">here</a>.
</p>
{% endif %}
<!-- Show feeds without webhooks -->
{% if broken_feeds %}
<div class="p-2 mb-2 border border-dark">
<ul class="list-group text-danger">Feeds without webhook:
{% for broken_feed in broken_feeds %}
<a class="text-muted"
href="/feed?feed_url={{ broken_feed.url|encode_url }}">{{ broken_feed.url }}</a>
{% endfor %}
</ul>
</div>
{% endif %}
</ul>
{% endblock %}