public Keep Put(int id, [FromBody] Keep keep) { if (ModelState.IsValid) { return(db.GetOneByIdAndUpdate(id, keep)); } return(null); }
public ActionResult <Keep> Put(int id, [FromBody] Keep keep) { Keep result = _repo.GetOneByIdAndUpdate(id, keep); if (result != null) { return(result); } return(NotFound()); }