diff --git a/klotz.go b/klotz.go index 15d0f56..67bd59b 100644 --- a/klotz.go +++ b/klotz.go @@ -22,6 +22,7 @@ type Anime struct { ImageMediumURL string `json:"imageMedium"` ImageLargeURL string `json:"imageLarge"` ImageThumbURL string `json:"imageThumb"` + URL string `json:"url"` Type string `json:"type"` Status string `json:"status"` Episodes int `json:"episodes"` diff --git a/schaffer.go b/schaffer.go index d79fbcc..2563e98 100644 --- a/schaffer.go +++ b/schaffer.go @@ -46,6 +46,7 @@ func JikanConvert(jik *SeasonAnimeJikan) Anime { Name: s.Name, }) } + res.URL = fmt.Sprintf("https://myanimelist.net/anime/%d", res.Anime) return res } @@ -87,6 +88,7 @@ func MalConvert(mal *AnimeDetailMal) Anime { } res.StartDate, _ = time.Parse("2006-01-02", mal.StartDate) res.EndDate, _ = time.Parse("2006-01-02", mal.EndDate) + res.URL = fmt.Sprintf("https://myanimelist.net/anime/%d", res.Anime) return res }