Esempio n. 1
0
        public async Task <IActionResult> Get(int id)
        {
            var exercise = await _exercisesRepository.GetAsync(id);

            if (exercise is null)
            {
                return(NotFound());
            }

            var result = _mapper.Map <ExerciseDto>(exercise);

            return(Ok(result));
        }