public async Task <IActionResult> Create(AdModel ad) { try { if (ModelState.IsValid) { return(HttpResponse.Send(true, 201, await _adService.Create(ad), null)); } return(HttpResponse.Send(true, 400, ModelState, null)); } catch (AppException ex) { return(HttpResponse.Send(false, ex.Code, null, ex.Message)); } }