diff options
author | 2020-09-27 16:01:06 -0700 | |
---|---|---|
committer | 2020-09-27 20:04:48 -0700 | |
commit | c394a61a4e1fe395191262ed1ccaf70b90a71484 (patch) | |
tree | ca3080c4eeb29f3a01d47676be9521334e0696cd /ui | |
parent | 16b7b3bc3e4237abbacdf8695a685ca9a03dc5bb (diff) | |
download | v2-c394a61a4e1fe395191262ed1ccaf70b90a71484.tar.gz v2-c394a61a4e1fe395191262ed1ccaf70b90a71484.tar.zst v2-c394a61a4e1fe395191262ed1ccaf70b90a71484.zip |
Add Prometheus exporter
Diffstat (limited to 'ui')
43 files changed, 52 insertions, 52 deletions
diff --git a/ui/about.go b/ui/about.go index 5bb9f6b3..7a27c9ed 100644 --- a/ui/about.go +++ b/ui/about.go @@ -7,8 +7,8 @@ package ui // import "miniflux.app/ui" import ( "net/http" - "miniflux.app/http/response/html" "miniflux.app/http/request" + "miniflux.app/http/response/html" "miniflux.app/ui/session" "miniflux.app/ui/view" "miniflux.app/version" @@ -28,7 +28,7 @@ func (h *handler) showAboutPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("about")) } diff --git a/ui/api_key_create.go b/ui/api_key_create.go index 87f87394..c33f8d0e 100644 --- a/ui/api_key_create.go +++ b/ui/api_key_create.go @@ -28,7 +28,7 @@ func (h *handler) showCreateAPIKeyPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("create_api_key")) } diff --git a/ui/api_key_list.go b/ui/api_key_list.go index 2b4d06ab..0e6a8cd7 100644 --- a/ui/api_key_list.go +++ b/ui/api_key_list.go @@ -33,7 +33,7 @@ func (h *handler) showAPIKeysPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("api_keys")) } diff --git a/ui/api_key_save.go b/ui/api_key_save.go index f8206af0..4c7dfc59 100644 --- a/ui/api_key_save.go +++ b/ui/api_key_save.go @@ -32,7 +32,7 @@ func (h *handler) saveAPIKey(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) if err := apiKeyForm.Validate(); err != nil { view.Set("errorMessage", err.Error()) diff --git a/ui/bookmark_entries.go b/ui/bookmark_entries.go index 5bf107ea..2b8a31d8 100644 --- a/ui/bookmark_entries.go +++ b/ui/bookmark_entries.go @@ -52,7 +52,7 @@ func (h *handler) showStarredPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "starred") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("bookmark_entries")) diff --git a/ui/category_create.go b/ui/category_create.go index d8fe2cfa..c61b2407 100644 --- a/ui/category_create.go +++ b/ui/category_create.go @@ -25,7 +25,7 @@ func (h *handler) showCreateCategoryPage(w http.ResponseWriter, r *http.Request) view.Set("menu", "categories") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("create_category")) } diff --git a/ui/category_edit.go b/ui/category_edit.go index 344cfe4e..f21a63a7 100644 --- a/ui/category_edit.go +++ b/ui/category_edit.go @@ -45,7 +45,7 @@ func (h *handler) showEditCategoryPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "categories") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("edit_category")) } diff --git a/ui/category_entries.go b/ui/category_entries.go index 09a6fd16..48a28939 100644 --- a/ui/category_entries.go +++ b/ui/category_entries.go @@ -64,7 +64,7 @@ func (h *handler) showCategoryEntriesPage(w http.ResponseWriter, r *http.Request view.Set("menu", "categories") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) view.Set("showOnlyUnreadEntries", true) diff --git a/ui/category_entries_all.go b/ui/category_entries_all.go index ab2f725b..d6cc55f6 100644 --- a/ui/category_entries_all.go +++ b/ui/category_entries_all.go @@ -64,7 +64,7 @@ func (h *handler) showCategoryEntriesAllPage(w http.ResponseWriter, r *http.Requ view.Set("menu", "categories") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) view.Set("showOnlyUnreadEntries", false) diff --git a/ui/category_feeds.go b/ui/category_feeds.go index 202fc3e4..cbcce7bd 100644 --- a/ui/category_feeds.go +++ b/ui/category_feeds.go @@ -46,7 +46,7 @@ func (h *handler) showCategoryFeedsPage(w http.ResponseWriter, r *http.Request) view.Set("menu", "categories") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("category_feeds")) } diff --git a/ui/category_list.go b/ui/category_list.go index 3137b956..1375888a 100644 --- a/ui/category_list.go +++ b/ui/category_list.go @@ -7,9 +7,9 @@ package ui // import "miniflux.app/ui" import ( "net/http" + "miniflux.app/http/request" "miniflux.app/http/response/html" "miniflux.app/ui/session" - "miniflux.app/http/request" "miniflux.app/ui/view" ) @@ -33,7 +33,7 @@ func (h *handler) showCategoryListPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "categories") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("categories")) } diff --git a/ui/category_save.go b/ui/category_save.go index 48fe4b60..fe8f11d3 100644 --- a/ui/category_save.go +++ b/ui/category_save.go @@ -7,9 +7,9 @@ package ui // import "miniflux.app/ui" import ( "net/http" + "miniflux.app/http/request" "miniflux.app/http/response/html" "miniflux.app/http/route" - "miniflux.app/http/request" "miniflux.app/logger" "miniflux.app/model" "miniflux.app/ui/form" @@ -32,7 +32,7 @@ func (h *handler) saveCategory(w http.ResponseWriter, r *http.Request) { view.Set("menu", "categories") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) if err := categoryForm.Validate(); err != nil { view.Set("errorMessage", err.Error()) diff --git a/ui/category_update.go b/ui/category_update.go index 591063ac..38f148df 100644 --- a/ui/category_update.go +++ b/ui/category_update.go @@ -44,7 +44,7 @@ func (h *handler) updateCategory(w http.ResponseWriter, r *http.Request) { view.Set("menu", "categories") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) if err := categoryForm.Validate(); err != nil { view.Set("errorMessage", err.Error()) diff --git a/ui/entry_bookmark.go b/ui/entry_bookmark.go index a07859d7..86155713 100644 --- a/ui/entry_bookmark.go +++ b/ui/entry_bookmark.go @@ -77,7 +77,7 @@ func (h *handler) showStarredEntryPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "starred") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("entry")) diff --git a/ui/entry_category.go b/ui/entry_category.go index c2602572..d42dc020 100644 --- a/ui/entry_category.go +++ b/ui/entry_category.go @@ -80,7 +80,7 @@ func (h *handler) showCategoryEntryPage(w http.ResponseWriter, r *http.Request) view.Set("menu", "categories") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("entry")) diff --git a/ui/entry_feed.go b/ui/entry_feed.go index e4ea585d..6eebc905 100644 --- a/ui/entry_feed.go +++ b/ui/entry_feed.go @@ -80,7 +80,7 @@ func (h *handler) showFeedEntryPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("entry")) diff --git a/ui/entry_read.go b/ui/entry_read.go index df79d444..f67c0218 100644 --- a/ui/entry_read.go +++ b/ui/entry_read.go @@ -67,7 +67,7 @@ func (h *handler) showReadEntryPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "history") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("entry")) diff --git a/ui/entry_search.go b/ui/entry_search.go index d9955334..fcdb3aef 100644 --- a/ui/entry_search.go +++ b/ui/entry_search.go @@ -80,7 +80,7 @@ func (h *handler) showSearchEntryPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "search") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("entry")) diff --git a/ui/entry_unread.go b/ui/entry_unread.go index 414b8e88..af006ea8 100644 --- a/ui/entry_unread.go +++ b/ui/entry_unread.go @@ -84,7 +84,7 @@ func (h *handler) showUnreadEntryPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "unread") view.Set("user", user) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) // Fetching the counter here avoid to be off by one. view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) diff --git a/ui/feed_edit.go b/ui/feed_edit.go index 3dddb1b7..19905828 100644 --- a/ui/feed_edit.go +++ b/ui/feed_edit.go @@ -65,7 +65,7 @@ func (h *handler) showEditFeedPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("defaultUserAgent", client.DefaultUserAgent) view.Set("hasProxyConfigured", config.Opts.HasHTTPClientProxyConfigured()) diff --git a/ui/feed_entries.go b/ui/feed_entries.go index 30aafa4d..04b56e53 100644 --- a/ui/feed_entries.go +++ b/ui/feed_entries.go @@ -64,7 +64,7 @@ func (h *handler) showFeedEntriesPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) view.Set("showOnlyUnreadEntries", true) diff --git a/ui/feed_entries_all.go b/ui/feed_entries_all.go index 1ce3abec..a5b1d7d5 100644 --- a/ui/feed_entries_all.go +++ b/ui/feed_entries_all.go @@ -64,7 +64,7 @@ func (h *handler) showFeedEntriesAllPage(w http.ResponseWriter, r *http.Request) view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) view.Set("showOnlyUnreadEntries", false) diff --git a/ui/feed_list.go b/ui/feed_list.go index 7c7b9225..761c803e 100644 --- a/ui/feed_list.go +++ b/ui/feed_list.go @@ -33,7 +33,7 @@ func (h *handler) showFeedsPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("feeds")) } diff --git a/ui/feed_update.go b/ui/feed_update.go index a5d830e9..81542c32 100644 --- a/ui/feed_update.go +++ b/ui/feed_update.go @@ -52,7 +52,7 @@ func (h *handler) updateFeed(w http.ResponseWriter, r *http.Request) { view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("defaultUserAgent", client.DefaultUserAgent) if err := feedForm.ValidateModification(); err != nil { diff --git a/ui/history_entries.go b/ui/history_entries.go index 7bee3946..efeb1d57 100644 --- a/ui/history_entries.go +++ b/ui/history_entries.go @@ -50,7 +50,7 @@ func (h *handler) showHistoryPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "history") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("history_entries")) diff --git a/ui/integration_show.go b/ui/integration_show.go index a43bb076..03d71e17 100644 --- a/ui/integration_show.go +++ b/ui/integration_show.go @@ -59,7 +59,7 @@ func (h *handler) showIntegrationPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasPocketConsumerKeyConfigured", config.Opts.PocketConsumerKey("") != "") html.OK(w, r, view.Render("integrations")) diff --git a/ui/opml_import.go b/ui/opml_import.go index 06f54bb9..ea6b3626 100644 --- a/ui/opml_import.go +++ b/ui/opml_import.go @@ -25,7 +25,7 @@ func (h *handler) showImportPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("import")) } diff --git a/ui/opml_upload.go b/ui/opml_upload.go index 6f9109bf..08430737 100644 --- a/ui/opml_upload.go +++ b/ui/opml_upload.go @@ -45,7 +45,7 @@ func (h *handler) uploadOPML(w http.ResponseWriter, r *http.Request) { view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) if fileHeader.Size == 0 { view.Set("errorMessage", "error.empty_file") @@ -86,7 +86,7 @@ func (h *handler) fetchOPML(w http.ResponseWriter, r *http.Request) { view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) clt := client.NewClientWithConfig(url, config.Opts) resp, err := clt.Get() diff --git a/ui/search_entries.go b/ui/search_entries.go index 054d7808..5dfd6db7 100644 --- a/ui/search_entries.go +++ b/ui/search_entries.go @@ -54,7 +54,7 @@ func (h *handler) showSearchEntriesPage(w http.ResponseWriter, r *http.Request) view.Set("menu", "search") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("search_entries")) diff --git a/ui/session_list.go b/ui/session_list.go index 28da2022..53051b2b 100644 --- a/ui/session_list.go +++ b/ui/session_list.go @@ -36,7 +36,7 @@ func (h *handler) showSessionsPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("sessions")) } diff --git a/ui/settings_show.go b/ui/settings_show.go index 8a8afbe7..a50f9760 100644 --- a/ui/settings_show.go +++ b/ui/settings_show.go @@ -51,7 +51,7 @@ func (h *handler) showSettingsPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("settings")) } diff --git a/ui/settings_update.go b/ui/settings_update.go index d4103d64..507fd833 100644 --- a/ui/settings_update.go +++ b/ui/settings_update.go @@ -7,8 +7,8 @@ package ui // import "miniflux.app/ui" import ( "net/http" - "miniflux.app/http/response/html" "miniflux.app/http/request" + "miniflux.app/http/response/html" "miniflux.app/http/route" "miniflux.app/locale" "miniflux.app/logger" @@ -43,7 +43,7 @@ func (h *handler) updateSettings(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) if err := settingsForm.Validate(); err != nil { view.Set("errorMessage", err.Error()) diff --git a/ui/shared_entries.go b/ui/shared_entries.go index 8d599441..0ba9cb19 100644 --- a/ui/shared_entries.go +++ b/ui/shared_entries.go @@ -45,7 +45,7 @@ func (h *handler) sharedEntries(w http.ResponseWriter, r *http.Request) { view.Set("menu", "history") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("shared_entries")) diff --git a/ui/subscription_add.go b/ui/subscription_add.go index e67f2510..920ceb40 100644 --- a/ui/subscription_add.go +++ b/ui/subscription_add.go @@ -36,7 +36,7 @@ func (h *handler) showAddSubscriptionPage(w http.ResponseWriter, r *http.Request view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("defaultUserAgent", client.DefaultUserAgent) view.Set("form", &form.SubscriptionForm{CategoryID: 0}) view.Set("hasProxyConfigured", config.Opts.HasHTTPClientProxyConfigured()) diff --git a/ui/subscription_bookmarklet.go b/ui/subscription_bookmarklet.go index bf1674ea..3b2c849e 100644 --- a/ui/subscription_bookmarklet.go +++ b/ui/subscription_bookmarklet.go @@ -39,7 +39,7 @@ func (h *handler) bookmarklet(w http.ResponseWriter, r *http.Request) { view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("defaultUserAgent", client.DefaultUserAgent) view.Set("hasProxyConfigured", config.Opts.HasHTTPClientProxyConfigured()) diff --git a/ui/subscription_choose.go b/ui/subscription_choose.go index 3df6e13a..68390e18 100644 --- a/ui/subscription_choose.go +++ b/ui/subscription_choose.go @@ -36,7 +36,7 @@ func (h *handler) showChooseSubscriptionPage(w http.ResponseWriter, r *http.Requ view.Set("menu", "feeds") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("defaultUserAgent", client.DefaultUserAgent) subscriptionForm := form.NewSubscriptionForm(r) diff --git a/ui/subscription_submit.go b/ui/subscription_submit.go index 44ca6f19..0eb11788 100644 --- a/ui/subscription_submit.go +++ b/ui/subscription_submit.go @@ -39,7 +39,7 @@ func (h *handler) submitSubscription(w http.ResponseWriter, r *http.Request) { v.Set("menu", "feeds") v.Set("user", user) v.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - v.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + v.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) v.Set("defaultUserAgent", client.DefaultUserAgent) v.Set("hasProxyConfigured", config.Opts.HasHTTPClientProxyConfigured()) @@ -102,7 +102,7 @@ func (h *handler) submitSubscription(w http.ResponseWriter, r *http.Request) { v.Set("menu", "feeds") v.Set("user", user) v.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - v.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + v.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) v.Set("hasProxyConfigured", config.Opts.HasHTTPClientProxyConfigured()) html.OK(w, r, v.Render("choose_subscription")) diff --git a/ui/unread_entries.go b/ui/unread_entries.go index e01c941f..57ff62b2 100644 --- a/ui/unread_entries.go +++ b/ui/unread_entries.go @@ -55,7 +55,7 @@ func (h *handler) showUnreadPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "unread") view.Set("user", user) view.Set("countUnread", countUnread) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("hasSaveEntry", h.store.HasSaveEntry(user.ID)) html.OK(w, r, view.Render("unread_entries")) diff --git a/ui/user_create.go b/ui/user_create.go index c3269b22..a30f3346 100644 --- a/ui/user_create.go +++ b/ui/user_create.go @@ -33,7 +33,7 @@ func (h *handler) showCreateUserPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("create_user")) } diff --git a/ui/user_edit.go b/ui/user_edit.go index 3d0289ce..23f577db 100644 --- a/ui/user_edit.go +++ b/ui/user_edit.go @@ -52,7 +52,7 @@ func (h *handler) showEditUserPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("edit_user")) } diff --git a/ui/user_list.go b/ui/user_list.go index 37850c71..6c19de41 100644 --- a/ui/user_list.go +++ b/ui/user_list.go @@ -7,8 +7,8 @@ package ui // import "miniflux.app/ui" import ( "net/http" - "miniflux.app/http/response/html" "miniflux.app/http/request" + "miniflux.app/http/response/html" "miniflux.app/ui/session" "miniflux.app/ui/view" ) @@ -40,7 +40,7 @@ func (h *handler) showUsersPage(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) html.OK(w, r, view.Render("users")) } diff --git a/ui/user_save.go b/ui/user_save.go index f1f60584..01d26deb 100644 --- a/ui/user_save.go +++ b/ui/user_save.go @@ -2,13 +2,13 @@ // Use of this source code is governed by the Apache 2.0 // license that can be found in the LICENSE file. -package ui // import "miniflux.app/ui" +package ui // import "miniflux.app/ui" import ( "net/http" - "miniflux.app/http/response/html" "miniflux.app/http/request" + "miniflux.app/http/response/html" "miniflux.app/http/route" "miniflux.app/logger" "miniflux.app/ui/form" @@ -35,7 +35,7 @@ func (h *handler) saveUser(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("form", userForm) if err := userForm.ValidateCreation(); err != nil { diff --git a/ui/user_update.go b/ui/user_update.go index 00b209d5..678b737e 100644 --- a/ui/user_update.go +++ b/ui/user_update.go @@ -47,7 +47,7 @@ func (h *handler) updateUser(w http.ResponseWriter, r *http.Request) { view.Set("menu", "settings") view.Set("user", user) view.Set("countUnread", h.store.CountUnreadEntries(user.ID)) - view.Set("countErrorFeeds", h.store.CountErrorFeeds(user.ID)) + view.Set("countErrorFeeds", h.store.CountUserFeedsWithErrors(user.ID)) view.Set("selected_user", selectedUser) view.Set("form", userForm) |