Ejemplo n.º 1
0
        public IActionResult Details(int id)
        {
            var model = _videos.Get(id);

            if (model == null)
            {
                return(RedirectToAction("Index"));
            }
            return(View(new VideoViewModel
            {
                Id = model.Id,
                Title = model.Title,
                Genre = model.Genre.ToString()
            }));
        }