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

Issue #3428454: Email subject with <em> html tag #3818

Merged
merged 1 commit into from
Mar 29, 2024

Conversation

vcsvinicius
Copy link
Contributor

@vcsvinicius vcsvinicius commented Mar 15, 2024

Problem

When processing activities such as creating a post in the stream it will send out emails. When there is no subject pre-defined it will will use the default Notification from %site_name, but the % placeholder when processed will surround the text with the HTML <em class="placeholder">. Since email subject html rendering can be different per email provider it can happen that this will show the HTML as raw.

Solution

Change the placeholder % to @ as this is similar to % but without the rendering of the HTML tag.

Issue tracker

PROD-28384
#3428454

Theme issue tracker

N/A

How to test

  • Create two diferent users with email
  • Access with user 1 and create a post
  • Access with user 2 and comment post created by user 1
  • Run cron
  • Check the email

Definition of done

Before merge

  • Code/peer review is completed
  • All commit messages are clear and clean. If applicable a rebase was performed
  • All automated tests are green
  • Functional/manual tests of the acceptance criteria are approved
  • All acceptance criteria were met
  • New features or changes to existing features are covered by tests, either unit (preferably) or behat
  • Update path is tested. New hook_updates should respect update order, right naming convention and consider hook_post_update code
  • Module can be safely uninstalled. Update/implement hook_uninstall and make sure that removed configuration or dependencies are removed/uninstalled
  • This pull request has all required labels (team/type/priority)
  • This pull request has a milestone
  • This pull request has an assignee (if applicable)
  • Any front end changes are tested on all major browsers
  • New UI elements, or changes on UI elements are approved by the design team
  • New features, or feature changes are approved by the product owner

After merge

  • Code is tested on all branches that it has been cherry-picked
  • Update hook number might need adjustment, make sure they have the correct order
  • The Drupal.org ticket(s) are updated according to this pull request status

Screenshots

N/A

Release notes

The Notification emails will stop to send html tag at subject.

Change Record

N/A

Translations

Notification from %site_name -> Notification from @site_name

@vcsvinicius vcsvinicius added type: bug Fixes a bug in Open Social status: needs review This pull request is waiting for a requested review prio: medium team: guardians labels Mar 15, 2024
@vcsvinicius vcsvinicius added this to the 12.3.0 milestone Mar 15, 2024
@vcsvinicius vcsvinicius requested a review from a team March 15, 2024 15:01
@ronaldtebrake ronaldtebrake modified the milestones: 12.3.0, 12.4.0 Mar 19, 2024
…e text and surround it with the <em> tag which not all email clients will render properly.
@robertragas robertragas force-pushed the bugfix/3428454/email-subject-with-html-tag branch from f3bcc1b to 45876ea Compare March 21, 2024 15:20
@robertragas robertragas merged commit 308f5a8 into main Mar 29, 2024
188 checks passed
@robertragas robertragas deleted the bugfix/3428454/email-subject-with-html-tag branch March 29, 2024 11:47
@robertragas
Copy link
Collaborator

Merged and cherry-picked to 12.4.x

@robertragas robertragas added status: no action needed backport: verified This pull request has been back ported to an older minor version labels Mar 29, 2024
@mergeable mergeable bot removed the backport: verified This pull request has been back ported to an older minor version label Mar 29, 2024
@robertragas robertragas added backport: verified This pull request has been back ported to an older minor version and removed status: needs review This pull request is waiting for a requested review labels Mar 29, 2024
@mergeable mergeable bot added status: needs review This pull request is waiting for a requested review and removed backport: verified This pull request has been back ported to an older minor version labels Mar 29, 2024
@ronaldtebrake ronaldtebrake added backport: verified This pull request has been back ported to an older minor version and removed status: needs review This pull request is waiting for a requested review labels Apr 9, 2024
@mergeable mergeable bot added the status: needs review This pull request is waiting for a requested review label Apr 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport: verified This pull request has been back ported to an older minor version prio: medium status: needs review This pull request is waiting for a requested review team: guardians type: bug Fixes a bug in Open Social
Development

Successfully merging this pull request may close these issues.

3 participants