public override List <VideoReference> GetVideos() { List <VideoReference> list = IMDbAPI.GetVideos(this.session, this.ID); if (this.Trailer != null) { // replace the reference with a details version int i = list.FindIndex(x => x.ID == this.Trailer.ID); if (i > -1) { list.RemoveAt(i); } // put the main trailer on top list.Insert(0, this.Trailer); } else if (this.trailer != null) { int i = list.FindIndex(x => x.ID == this.trailer); if (i > -1) { // move the video on top and rename the title VideoReference video = list[i]; video.Title = "Main Trailer"; list.RemoveAt(i); list.Insert(0, video); } } return(list); }
public virtual List <VideoReference> GetVideos() { return(IMDbAPI.GetVideos(this.session, this.ID)); }