From 7135733c29bece1808c24c918b1cbc86ebc0ca1a Mon Sep 17 00:00:00 2001 From: Eduard Urbach Date: Mon, 7 Oct 2019 13:47:51 +0900 Subject: [PATCH] Disabled third party image download --- arn/KitsuAnime.go | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/arn/KitsuAnime.go b/arn/KitsuAnime.go index ab283ceb..29d1c592 100644 --- a/arn/KitsuAnime.go +++ b/arn/KitsuAnime.go @@ -1,12 +1,9 @@ package arn import ( - "net/http" "strings" - "github.com/aerogo/http/client" "github.com/aerogo/nano" - "github.com/akyoto/color" "github.com/animenotifier/kitsu" ) @@ -47,17 +44,17 @@ func NewAnimeFromKitsuAnime(kitsuAnime *kitsu.Anime) (*Anime, *AnimeCharacters, } // Download image - response, err := client.Get(attr.PosterImage.Original).End() + // response, err := client.Get(attr.PosterImage.Original).End() - if err == nil && response.StatusCode() == http.StatusOK { - err := anime.SetImageBytes(response.Bytes()) + // if err == nil && response.StatusCode() == http.StatusOK { + // err := anime.SetImageBytes(response.Bytes()) - if err != nil { - color.Red("Couldn't set image for [%s] %s (%s)", anime.ID, anime, err.Error()) - } - } else { - color.Red("No image for [%s] %s (%d)", anime.ID, anime, response.StatusCode()) - } + // if err != nil { + // color.Red("Couldn't set image for [%s] %s (%s)", anime.ID, anime, err.Error()) + // } + // } else { + // color.Red("No image for [%s] %s (%d)", anime.ID, anime, response.StatusCode()) + // } // Rating if anime.Rating.IsNotRated() {