예제 #1
0
        public async Task <ActionResult <IReadOnlyCollection <BuildInfoDto> > > GetAsync()
        {
            try
            {
                var builds = await _buildService.GetBuildsAsync();

                return(Ok(_mapper.Map <IReadOnlyCollection <BuildInfoDto> >(builds)));
            }
            catch (Exception ex)
            {
                _logger.LogError(ex, "Error in BuildsController");
                return(StatusCode(500, ex.Message));
            }
        }