Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Mailer] mailchimp-transport "Undefined index: _id" when sending email #34892

Closed
@thomas-hiron

Description

@thomas-hiron

Symfony version(s) affected: 4.4.1

Description
Since version 4.4.1, I can't sent emails using mailchimp transport with mandrill+api scheme.

How to reproduce
Send a classic email with following code:

$email = (new Email())
    ->from(new Address("[email protected]"))
    ->to("[email protected]")
    ->subject("subject")
    ->text("text")
;

try {
    $mailer->send($email);
} catch (TransportExceptionInterface $e) {
}

You should have a notice error Notice: Undefined index: _id

After some digging, here is what happens : the doSendApi method from MandrillApiTransport tries to set the message id from the variable $result['_id'], but this variable is a multidimensional array :
image

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions