ruby / net-smtp

This library provides functionality to send internet mail via SMTP, the Simple Mail Transfer Protocol.
Other
44 stars 30 forks source link

Fix: enable_starttls before disable_tls causes an error. #10

Closed tmtm closed 4 years ago

tmtm commented 4 years ago

enable_starttls before disable_tls causes an error.

require 'net/smtp'

s = Net::SMTP.new("localhost", 25)
s.enable_starttls
s.disable_tls
s.start
#=> wrong argument type nil (expected OpenSSL/SSL/CTX) (TypeError)