Beispiel #1
0
        public async Task <IActionResult> Get(int id)
        {
            Singleton.Instance.Audit = false;
            var response = await _betsService.Get(id);

            if (response.Meta.Status)
            {
                return(Ok(response));
            }
            ModelState.AddModelError("Error", string.Join(",", response.Meta.Errors));
            return(BadRequest(ModelState));
        }
        private async Task <Bet> GetBet(int idBet)
        {
            var getGame = await _betsService.Get(idBet);

            object elementObject = GenericUtil.GetElementsResultService(getGame.Result);

            return((Bet)elementObject);
        }