I am trying to set up an app with send email option.
I have this code:
import Foundation
import MessageUI
import UIKit
class emailClass: UIViewContr
The problem with your code is, that the
// Present the view controller modally. self.present(composeVC, animated: true, completion: nil)
presents itself in itself ;-)
If you don´t know the current view controller, just display it on the RootViewController, i.e.
UIApplication.shared.keyWindow?.rootViewController?.present(...