public static MangaRate GetMangaRateByTitleId(int title_id) { try { return(new MangaRate(ShikiApiStatic.GetMangaFullInfo(title_id).UserRate)); } catch (Exception) { return(null); // not found title } }
public MangaRate(_UserRate_v2 rate_upd) { CompletedVolumes = rate_upd.volumes; CompletedChapters = rate_upd.chapters; UserStatus = rate_upd.status; Score = rate_upd.score; UserRateId = rate_upd.id; TitleId = rate_upd.target_id; var title = ShikiApiStatic.GetMangaFullInfo(TitleId); Name = title.Name; RusName = title.RusName; Poster = title.Poster; Url = title.Url; Kind = title.Kind; TitleStatus = title.TitleStatus; AiredOn = title.AiredOn; ReleasedOn = title.ReleasedOn; TotalVolumes = title.TotalVolumes; TotalChapters = title.TotalChapters; }