Example #1
0
        public async Task <IActionResult> Fight(FightRequestDto request)
        {
            ServiceResponse <FightResultDto> response = await _fightService.Fight(request);

            if (!response.Success)
            {
                return(BadRequest(response));
            }
            return(Ok(response));
        }
        public async Task <IActionResult> Fight(FightRequestDto fightRequestDto)
        {
            var response = await _service.Fight(fightRequestDto);

            if (!response.Success)
            {
                return(NotFound(response));
            }

            return(Ok(response));
        }
Example #3
0
 public async Task <IActionResult> Fight(FightRequestDto request)
 {
     return(Ok(await _fightService.Fight(request)));
 }
Example #4
0
 public async Task <ActionResult <ServiceResponse <FightRequestDto> > > Fight(FightRequestDto request)
 {
     return(Ok(await _fightService.Fight(request)));
 }
Example #5
0
 public async Task <IActionResult> Fight(FightRequestDto fightRequest) =>
 ActionResultHandler(await _fightService.Fight(fightRequest));