ASPNETCoreAngular2Demo.Controller.FoodItemsController.GetSingleFood C# (CSharp) Method

GetSingleFood() private method

private GetSingleFood ( int foodItemId ) : IActionResult
foodItemId int
return IActionResult
        public IActionResult GetSingleFood(int foodItemId)
        {
            FoodItem foodItem = _foodRepository.GetSingle(foodItemId);

            if (foodItem == null)
            {
                return NotFound();
            }

            return Ok(Mapper.Map<FoodItemViewModel>(foodItem));
        }