public async Task <ActionResult <RatingModel[]> > Get() { try { var results = await _repository.GetAllRatingsAsyc(); return(_mapper.Map <RatingModel[]>(results)); } catch (Exception ex) { return(StatusCode(StatusCodes.Status500InternalServerError, ex.Message)); } }