fixed stupid bug in closest points caused by my trying to refactor out complaints about hidden variables...