Within my "share location" function, I want the user to have the ability to send a text that shares their current location in the form of long/lat coordinates. The error I get with what I have implemented is "Contextual type "string" cannot be used with array literal". How or what is the correct code to implement?
Here's my code
@IBAction func shareLocation(sender: AnyObject) {
// Send user coordinates through text
if !MFMessageComposeViewController.canSendText() {
print("SMS services are not available")
var coordinate: CLLocationCoordinate2D
messageVC!.body = [coordinate.latitude, coordinate.longitude];
messageVC!.recipients = [LookoutCell.description()];
messageVC!.messageComposeDelegate = self;
self.presentViewController(messageVC!, animated: false, completion: nil)
}
}