public void EditPlan(string accessId, PlanDTO PlanDTO) { try { PlanService.Edit(PlanDTO); } catch (TimeoutException) { throw new HttpResponseException(new HttpResponseMessage(HttpStatusCode.RequestTimeout) { Content = new StringContent("An error occurred, please try again or contact the administrator."), ReasonPhrase = "Critical Exception" }); } catch (Exception) { throw new HttpResponseException(new HttpResponseMessage(HttpStatusCode.InternalServerError) { Content = new StringContent("An error occurred, please try again or contact the administrator."), ReasonPhrase = "Critical Exception" }); } }