mirror of
https://github.com/miniflux/v2.git
synced 2025-08-21 18:11:09 +00:00
Use image included in feed as feed icon
This commit is contained in:
parent
228bb62df4
commit
1aeb1b20da
8 changed files with 92 additions and 28 deletions
|
@ -28,6 +28,7 @@ type atom10Feed struct {
|
|||
ID string `xml:"id"`
|
||||
Title atom10Text `xml:"title"`
|
||||
Authors atomAuthors `xml:"author"`
|
||||
Icon string `xml:"icon"`
|
||||
Links atomLinks `xml:"link"`
|
||||
Entries []atom10Entry `xml:"entry"`
|
||||
}
|
||||
|
@ -54,6 +55,8 @@ func (a *atom10Feed) Transform(baseURL string) *model.Feed {
|
|||
feed.Title = feed.SiteURL
|
||||
}
|
||||
|
||||
feed.IconURL = strings.TrimSpace(a.Icon)
|
||||
|
||||
for _, entry := range a.Entries {
|
||||
item := entry.Transform()
|
||||
entryURL, err := url.AbsoluteURL(feed.SiteURL, item.URL)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue