drewblas / aws-ses

Provides an easy ruby DSL & interface to AWS SES
MIT License
549 stars 109 forks source link

Definition of source as e.g. "John Doe <foo@bar.com>" not being used #61

Open fschaeffler opened 9 years ago

fschaeffler commented 9 years ago

When I try to send an email with a request like the following, my source gets replaced from "John Doe smith@foobar.com" to "FooBar Smith", no matter to what I change my source. The means my email-client displays "FooBar Smith" as the actual sender-text. Any ideas on the misbehaviour?

Code: ses.send_email(:to => ['ruby@schf.de'], :source => '"John Doe smith@foobar.com"', :subject => 'test', :text_body => 'Test 111222333')

yyamano commented 9 years ago

I tried with '"John Doe smith@foobar.com"', but I got the following error. I think the source should be 'John Doe smith@foobar.com'

/home/vagrant/apis-made-easy/vendor/bundle/ruby/gems/aws-ses-0.6.0/lib/aws/ses/base.rb:176:in `request': InvalidParameterValue - Missing final '@domain' (AWS::SES::ResponseError)
    from /home/vagrant/apis-made-easy/vendor/bundle/ruby/gems/aws-ses-0.6.0/lib/aws/ses/send_email.rb:70:in `send_email'
    from ses.rb:11:in `<main>'