That got my past that error, however still had trouble with SMTP connections.
PHPMailer is using opportunistic TLS by default, if the user selects no encryption you should disable this. Default mail server configs will enable a snakeoil certificate that will fail validation.
From SMTPMailer’s documentation:
PHPMailer 5.2.10 introduced opportunistic TLS – if it sees that the server is advertising TLS encryption (after you have connected to the server), it enables encryption automatically, even if you have not set SMTPSecure. This might cause issues if the server is advertising TLS with an invalid certificate, but you can turn it off with $mail->SMTPAutoTLS = false;.