Fixed the haversine formula to calculate distance between 2 points properly