rename Map getDistance to distance