I currently have a PFGeoPoint on a Parse Server which I can successfully retrieve by doing the following (in Swift):
let geo = listingObject?.objectForKey("geo")
// <PFGeoPoint: 0x7ff37d184840, latitude: 51.510005, longitude: -0.128493>
What I am now wanting to do is get the latitude and longitude out of this into their own variables.
When I create a map annotation for example the following works:
let anno = mapAnnotation(coordinate: CLLocationCoordinate2D(latitude: (geo?.latitude)!, longitude: (geo?.longitude)!))
However this produces an error:
let latitude = geo?.latitude
// Ambiguous use of 'latitude'
Can anyone point me in right direction?