public HttpResponseMessage InsertCourse([FromBody] CourseEntity Course) { HttpResponseMessage response = Request.CreateResponse(HttpStatusCode.InternalServerError); try { CoursesManager courseManager = new CoursesManager(); courseManager.InsertCourse(Course); response = Request.CreateResponse(HttpStatusCode.OK); } catch (Exception ex) { response.Content = new StringContent($"{GENERIC_ERROR} [{ex.Message}]"); DbLog.LogError("Error in CoursesController", ex); } return(response); }