MFMailComposeViewControllerDelegate not being called

前端 未结 4 1508
北恋
北恋 2021-01-20 02:08

I realize this question has been inexactly asked around, but I haven\'t been able to find an answer to my problem.

I have a UITableViewController with static cells.

4条回答
  •  萌比男神i
    2021-01-20 02:39

    mailCVP.delegate = self
    mailCVP = configureMailComposeVC()
    

    This code sets the delegate but then creates a new instance, which doesn't have a delegate...

    Note that there is also no point in creating the VC instance if MFMailComposeViewController.canSendMail returns false.

提交回复
热议问题