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
fix: check if salutation already exists in email body #13196
fix: check if salutation already exists in email body #13196
Conversation
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed within 3 days if no further activity occurs, but it only takes a comment to keep a contribution alive :) Also, even if it is closed, you can always reopen the PR when you're ready. Thank you for contributing. |
@Mergifyio backport version-13-hotfix develop |
Command
|
const SALUTATION_END_COMMENT = "<!-- salutation-ends -->"; | ||
if (this.real_name && !message.includes(SALUTATION_END_COMMENT)) { | ||
this.message = ` | ||
<p>${__('Dear')} ${this.real_name},</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for fixing! By the way, __('Dear')
is impossible to translate correctly without knowing how it is used here. __('Dear {},', [this.real_name], 'Salutation in Email')
would be a bit easier.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed with #13503
Prevents salutation from being rendered multiple times.