Skip to content

Commit

Permalink
Merge pull request #31 from dgvz/master
Browse files Browse the repository at this point in the history
Add attr_accessor for cc_name and bcc_name
  • Loading branch information
thinkingserious committed Nov 26, 2015
2 parents 580d614 + 781e2e8 commit bb5178c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,9 @@ params = {
:text,
:html,
:cc,
:cc_name,
:bcc,
:bcc_name,
:reply_to,
:date,
:smtpapi,
Expand Down
6 changes: 4 additions & 2 deletions lib/sendgrid/mail.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

module SendGrid
class Mail
attr_accessor :to, :to_name, :from, :from_name, :subject, :text, :html, :cc,
:bcc, :reply_to, :date, :smtpapi, :attachments, :content, :template
attr_accessor :to, :to_name, :from, :from_name, :subject, :text, :html, :cc, :cc_name,
:bcc, :bcc_name, :reply_to, :date, :smtpapi, :attachments, :content, :template

def initialize(params = {})
params.each do |k, v|
Expand Down Expand Up @@ -139,7 +139,9 @@ def to_h
:date => date,
:replyto => reply_to,
:cc => cc,
:ccname => cc_name,
:bcc => bcc,
:bccname => bcc_name,
:text => text,
:html => html,
:'x-smtpapi' => smtpapi_json,
Expand Down

0 comments on commit bb5178c

Please sign in to comment.