Skip to content

Order of methods matter in Email::Stuffer 0.012 #24

Description

@szabgab

I just bumped into this issue using Email::Stuffer 0.012

If I create the email this way:

Email::Stuffer->text_body($text)->subject($subject)->from($from)->to($to)->send;

The generated e-mail in my Mailfolder looks like this:


Date: Thu, 7 May 2015 19:47:04 +0300
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"; format="flowed"
Content-Transfer-Encoding: quoted-printable
Subject: Experiment
X-Email-Sender-From: gabor@perlmaven.com
X-Email-Sender-To: gabor@szabgab.com
Lines: 1

Text

and the message is rejected by Google due to lack of RFC conformity.

If I change the order of the calls to

Email::Stuffer->text_body($text)->from($from)->to($to)->subject($subject)->send;


Date: Thu, 7 May 2015 19:51:12 +0300
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8";
format="flowed"Content-Transfer-Encoding: quoted-printable
From: G Sz gabor@perlmaven.com
To: gabor@szabgab.com
Subject: Experiment
X-Email-Sender-From: gabor@perlmaven.com
X-Email-Sender-To: gabor@szabgab.com
Lines: 2

Experimental message


and the message is delivered properly.

I don't think I saw in the docs that the order matters. So this seems to be
either a bug in the code or a need to updated the docs.

(also reported as https://rt.cpan.org/Ticket/Display.html?id=104299 sorry for that.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions