2 files changed,
9 insertions(+),
1 deletions(-)
Author:
Oleksandr Smirnov
olexsmir@gmail.com
Committed at:
2026-06-02 13:52:19 +0300
Authored at:
2026-06-02 13:51:04 +0300
Change ID:
xqrsxkupslnktnnklvvkptrxqsxxqylp
Parent:
a5ac527
jump to
| M | app/atom/feed.go |
| M | sources/twitch/twitch.go |
M
app/atom/feed.go
··· 34 34 return f 35 35 } 36 36 37 +func (f *Feed) WithLink(rel, href string) *Feed { 38 + if href != "" { 39 + f.Link = append(f.Link, Link{Rel: rel, Href: href}) 40 + } 41 + return f 42 +} 43 + 37 44 func (f *Feed) Add(entry *Entry) *Feed { 38 45 if entry != nil { 39 46 f.Entry = append(f.Entry, entry)
M
sources/twitch/twitch.go
··· 92 92 return 93 93 } 94 94 95 - feed := atom.NewFeed("Twitch: "+name, "twitch:"+name) 95 + feed := atom.NewFeed("Twitch: "+name, "twitch:"+name). 96 + WithLink("alternate", "https://twitch.tv/"+name) 96 97 if stream != nil { 97 98 feed.Add(entryFromStream(stream)) 98 99 }