Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[5.8] Fix default theme for Markdown mails #29274

Merged
merged 2 commits into from Jul 25, 2019
Merged

[5.8] Fix default theme for Markdown mails #29274

merged 2 commits into from Jul 25, 2019

Conversation

ghost
Copy link

@ghost ghost commented Jul 23, 2019

As metioned in this comment on pr #29132,
the pull request breaks the config mail.markdown.theme because it will be overwrited on:

if (property_exists($message, 'theme') && ! is_null($message->theme)) {
$this->markdown->theme($message->theme);
}

This PR leave the MailMessage::$theme null so MailChannel will ignore it.
The feature added in PR #29132 still available.

we don't need to set default theme value here.
The default theme is take care in Illuminate\Mail\Markdown::__constractut.
Leave it null as default so config('mail.markdown.theme') can take effect.
The default value of theme make the function no longger be called, it only called if it has value
@ghost
Copy link
Author

ghost commented Jul 24, 2019

cc @jackwh, @troccoli can you take a look on this?

I wonder if there need to add more test?

@taylorotwell taylorotwell merged commit e476a94 into laravel:5.8 Jul 25, 2019
@ghost ghost deleted the fix-markdown-default-theme branch July 30, 2019 08:01
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.

2 participants