public IHttpActionResult GetSubjectById(int id) { var subject = subjectRepo.GetById(id); if (subject == null) { return(Content(HttpStatusCode.NotFound, "Item does not exist")); } return(Ok(subject)); }