public HttpResponseMessage PatchDeploy(int id, Delta <Deploy> newDeploy) { using (dbMainEntities objContext = new dbMainEntities()) { Deploy deploy = objContext.Deploys.SingleOrDefault(p => p.depID == id); if (deploy == null) { throw new HttpResponseException(HttpStatusCode.NotFound); } newDeploy.Patch(deploy); objContext.SaveChanges(); } return(Request.CreateResponse(HttpStatusCode.NoContent)); }