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

Skip to content

[5.2] Fix SparkPost doesn't send attachments#13577

Merged
taylorotwell merged 2 commits into
laravel:5.2from
billmn:sparkpost-attachments
May 17, 2016
Merged

[5.2] Fix SparkPost doesn't send attachments#13577
taylorotwell merged 2 commits into
laravel:5.2from
billmn:sparkpost-attachments

Conversation

@billmn
Copy link
Copy Markdown
Contributor

@billmn billmn commented May 16, 2016

@billmn billmn changed the title [5.2] Fix SparkPost doesn't send attachments #13546 [5.2] Fix SparkPost doesn't send attachments May 16, 2016
@taylorotwell taylorotwell merged commit a2058cb into laravel:5.2 May 17, 2016
@billmn billmn deleted the sparkpost-attachments branch May 25, 2016 16:48
@RicardoRamirezR
Copy link
Copy Markdown

RicardoRamirezR commented May 26, 2016

Hi there,

After this fix, I'm getting:

Call to undefined method Swift_MimePart::getFileName()
vendor/laravel/framework/src/Illuminate/Mail/Transport/SparkPostTransport.php:68

Going to laravel/framework (v5.2.31) clear the issue

Note: _children is empty

capture d ecran 2016-05-25 a 11 13 42 pm

@billmn
Copy link
Copy Markdown
Contributor Author

billmn commented May 26, 2016

@treserres Can you post your code?
I have used this code and it works fine:

Mail::send('mail', [], function($mail) {
    $mail->to('[email protected]')->subject('Sparkpost test');
});

Also my test has an empty "_children" array:
schermata 2016-05-26 alle 09 19 49

@RicardoRamirezR
Copy link
Copy Markdown

RicardoRamirezR commented May 26, 2016

Sure, here is:

Route::get('/tm', function () {

    $message = 'Muy buenos días';

    $data = [
        'from_name' => 'rrr',
        'to_name' => 'rrr',
        'body' => $message,
    ];

    Mail::send([
            "emails.you-have-new-notification",
            "emails.you-have-new-notification-plain",
        ],
        $data,
        function ($message) {
            $message
                ->to('[email protected]', 'Ricardo')
                ->subject('Ricardo le ha enviado mensaje');
        }
    );
});

@eleftrik
Copy link
Copy Markdown

I have the same issue reported by @treserres

@billmn
Copy link
Copy Markdown
Contributor Author

billmn commented May 28, 2016

Call to undefined method Swift_MimePart::getFileName()

@treserres This error because the message plain version is in getChildren() array. Soon a fix.

@kezkankrayon
Copy link
Copy Markdown

I have the same issue reported by @treserres.

@taylorotwell
Copy link
Copy Markdown
Member

Does anyone have a fix?

On Sat, May 28, 2016 at 6:00 AM -0700, "kezkankrayon" [email protected] wrote:

I have the same issue reported by @treserres.


You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub, or mute the thread.

@billmn
Copy link
Copy Markdown
Contributor Author

billmn commented May 28, 2016

@taylorotwell Yes but I'm testing the fix in different cases: billmn@fea984d

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants