public async Task <IHttpActionResult> EditType(int id) { if (id < 1) { return(BadRequest()); } try { var dto = await _kudosService.GetKudosTypeAsync(id, GetUserAndOrganization()); var result = _mapper.Map <KudosTypeDto, KudosTypeViewModel>(dto); return(Ok(result)); } catch (ValidationException e) { return(BadRequestWithError(e)); } }