internal Lego GetById(int id) { var exists = _repo.GetById(id); if (exists == null) { throw new Exception("Invalid Id"); } return(exists); }
internal Lego GetById(int id) { Lego foundLego = _repo.GetById(id); if (foundLego == null) { throw new Exception("Invalid id."); } return(foundLego); }