Exemplo n.º 1
0
        public async Task <ActionResult <Trainer> > GetById(int id)
        {
            var trainer = await _trainerService.GetTrainerByIdAsync(id);

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

            return(Ok(trainer));
        }