[英]error in implementing completion in iOS swift
let mailComposeViewController = self.configuredMailComposeViewController(randomNumber, email: email!)
if MFMailComposeViewController.canSendMail()
{
self.presentViewController(mailComposeViewController, animated: true, completion { () -> Void in
self.securityCode(randomNumber, email: email!)
})
}
else
{
self.showSendMailErrorAlert()
}
您未正確使用完成功能。 這樣使用
self.presentViewController(mailComposeViewController, animated:true) { () -> Void in
self.securityCode(randomNumber, email: email!)
}
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.