aboutsummaryrefslogtreecommitdiff
path: root/internal/model/feed.go
diff options
context:
space:
mode:
authorGravatar Frédéric Guillot <f@miniflux.net> 2023-10-21 19:50:29 -0700
committerGravatar Frédéric Guillot <f@miniflux.net> 2023-10-22 13:09:30 -0700
commit14e25ab9fe09b9951b38e56af2bdff7a0737b280 (patch)
tree1e466305ccf868d0253b09895af29f811a3e3393 /internal/model/feed.go
parent120aabfbcef4ef453d70861aece3b107b603a911 (diff)
downloadv2-14e25ab9fe09b9951b38e56af2bdff7a0737b280.tar.gz
v2-14e25ab9fe09b9951b38e56af2bdff7a0737b280.tar.zst
v2-14e25ab9fe09b9951b38e56af2bdff7a0737b280.zip
Refactor HTTP Client and LocalizedError packages
Diffstat (limited to 'internal/model/feed.go')
-rw-r--r--internal/model/feed.go12
1 files changed, 2 insertions, 10 deletions
diff --git a/internal/model/feed.go b/internal/model/feed.go
index 9e2b89e8..88560a27 100644
--- a/internal/model/feed.go
+++ b/internal/model/feed.go
@@ -9,7 +9,6 @@ import (
"time"
"miniflux.app/v2/internal/config"
- "miniflux.app/v2/internal/http/client"
)
// List of supported schedulers.
@@ -79,20 +78,13 @@ func (f *Feed) String() string {
)
}
-// WithClientResponse updates feed attributes from an HTTP request.
-func (f *Feed) WithClientResponse(response *client.Response) {
- f.EtagHeader = response.ETag
- f.LastModifiedHeader = response.LastModified
- f.FeedURL = response.EffectiveURL
-}
-
// WithCategoryID initializes the category attribute of the feed.
func (f *Feed) WithCategoryID(categoryID int64) {
f.Category = &Category{ID: categoryID}
}
-// WithError adds a new error message and increment the error counter.
-func (f *Feed) WithError(message string) {
+// WithTranslatedErrorMessage adds a new error message and increment the error counter.
+func (f *Feed) WithTranslatedErrorMessage(message string) {
f.ParsingErrorCount++
f.ParsingErrorMsg = message
}