public async Task <ActionResult> Post(DtoFitnessPath fitnessPath)
        {
            var path = mapper.Map <FitnessPath>(fitnessPath, opt => { opt.Items["UserId"] = User.Identity.GetId(); });
            var createdFitnessPath = await fitnessPathRepository.Create(path);

            return(Created(configService.GenerateCreatedUrl(controllerName, createdFitnessPath.Id), createdFitnessPath));
        }
 public async Task Put(long id, DtoFitnessPath fitnessPath)
 {
     var path = mapper.Map <FitnessPath>(fitnessPath, opt => { opt.Items["UserId"] = User.Identity.GetId(); });
     await fitnessPathRepository.UpdateEntity(id, path);
 }