Пример #1
0
        public async Task <IActionResult> Get([FromRoute] Guid id)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState));
            }

            var card = await cardRepo.FirstOrDefaultAsync(id);

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

            return(Ok(card));
        }