I found that you are getting the correct array for the bcc, maybe you have the wrong email address.
When the email address contains a dot before @, for example test. @ test.com, and presented as part of the array, you get the undefined `encoding 'method for Array. The error appears only in Ruby 1.9, and only if the address is presented as an array.
try it
def call_email(users_emails, mesesage_subject, mesesage_body) @users_emails = users_emails @mesesage_subject = mesesage_subject @mesesage_body = mesesage_body mail( :bcc => @users_emails.join(','), :subject => @mesesage_subject, :body => @mesesage_body) do |format| format.html end end
source share