fix(all): accept Into<SendableEmail>
When sending a mail, accept not only `SendableEmail`, but also anything that can be converted .into() a `SendableEmail`.
This commit is contained in:
@@ -67,7 +67,7 @@ fn main() {
|
||||
// Open a local connection on port 25
|
||||
let mut mailer = SmtpClient::new_unencrypted_localhost().unwrap().transport();
|
||||
// Send the email
|
||||
let result = mailer.send(email.into());
|
||||
let result = mailer.send(email);
|
||||
|
||||
if result.is_ok() {
|
||||
println!("Email sent");
|
||||
|
||||
Reference in New Issue
Block a user