Exemple #1
0
        public async Task <IActionResult> GetAsync(string id)
        {
            var result = await _service.Get(id);

            if (result.IsSuccess)
            {
                return(Ok(result.Value));
            }
            else
            {
                return(BadRequest(result.Error));
            }
        }