This question already has an answer here:
- xcode 6 beta 4 - MessageComposeResult is not convertible to OptionalNilComparisonType 4 answers
I am attempting to implement the MFMessageComposeViewControllerDelegate's required method
func messageComposeViewController(controller: MFMessageComposeViewController, didFinishWithResult result: MessageComposeResult) {
}
The issue is that I can't figure out how to compare the MessageComposeResult with its associated constants in swift(MessageComposeResultCancelled, MessageComposeResultSent, MessageComposeResultFailed). So far I have tried:
result == MessageComposeResultCancelled
and
result == MessageComposeResult(0)
both of which return the error "'MessageComposeResult' is not convertible to MirrorDisposition". Any insight on how I can resolve this error would be greatly appreciated.