fix: show username on cert if name is private (#40897)
Co-authored-by: Shaun Hamilton <51722130+ShaunSHamilton@users.noreply.github.com>
This commit is contained in:
@ -423,7 +423,7 @@ function createShowCert(app) {
|
||||
]
|
||||
});
|
||||
}
|
||||
const { isLocked, showCerts } = user.profileUI;
|
||||
const { isLocked, showCerts, showName } = user.profileUI;
|
||||
|
||||
if (!user.name) {
|
||||
return res.json({
|
||||
@ -512,6 +512,16 @@ function createShowCert(app) {
|
||||
}
|
||||
|
||||
const { username, name } = user;
|
||||
|
||||
if (!showName) {
|
||||
return res.json({
|
||||
certTitle,
|
||||
username,
|
||||
date: completedDate,
|
||||
completionTime
|
||||
});
|
||||
}
|
||||
|
||||
return res.json({
|
||||
certTitle,
|
||||
username,
|
||||
|
Reference in New Issue
Block a user