TMail::Mail.sender_addr=?

I’m trying to use the TMail classes. When I do the following:

mail = TMail::Mail.new
sender_addr = TMail::Address.parse("[email protected]")
sender_addr.name = "Foo B."
mail.sender_addr = sender_addr

I get this error:

undefined method `addr=’ for #<TMail::SingleAddressHeader “”>

Anyone have a clue how to make this work?

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs