// GET: Words/Details/5 public async Task <IActionResult> Details(int?id) { if (id == null) { return(NotFound()); } var userId = User.GetUserId(); var word = await _service.GetAsync(userId, id.Value); if (word == null) { return(NotFound()); } return(View(_mapper.Map <WordViewModel>(word))); }