Token replacement leads to Anonymous user or invalid user

Created on 8 April 2025, 5 months ago

Problem/Motivation

When a user invites people to join the basic course, there will be an email sent to the recipient. However, there is an issue on the email signature that written on email body:

1. If email already registered as a user: email signature is written by the recipient name, instead of sender name.
2. If email is not yet registered as a user: no recipient name on the on email body and no email signature (sender name)

Steps to reproduce

1. Access a course page
2. Go to “manage member” tab
3. Click on “Add member” button on the top right corner, choose “invite users”
4. Input the email address of recipient
5. Then send the invitation
6. Check the email

Proposed resolution

During Open Social's move from Swift Mailer to Symfony mailer. The token [current-user:display-name] was replaced with [user:display-name] in invite_subject and invite_message.

This was somehow missed for Social Courses. We need to replace those tokens.

🐛 Bug report
Status

Active

Version

6.2

Component

Code

Created by

🇪🇸Spain navneet0693 Madrid

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024