Skip to content

Commit

Permalink
fix: fix slack resonse replied anonymous notification (#9390)
Browse files Browse the repository at this point in the history
  • Loading branch information
igorlesnenko committed Jan 30, 2024
1 parent 027579e commit 1717936
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,8 @@ const getSlackMessageForNotification = async (
const author = await dataLoader.get('users').loadNonNull(notification.authorId)
const comment = await dataLoader.get('comments').load(notification.commentId)

const authorName = comment.isAnonymous ? 'Anonymous' : author.preferredName

const options = {
searchParams: {
utm_source: 'slack standup notification',
Expand All @@ -274,7 +276,7 @@ const getSlackMessageForNotification = async (
const buttonUrl = makeAppURL(appOrigin, `meet/${notification.meetingId}/responses`, options)
return {
buttonUrl,
title: `*${author.preferredName}* replied to your response in *${meeting.name}*`,
title: `*${authorName}* replied to your response in *${meeting.name}*`,
body: `> ${comment.plaintextContent}`,
buttonText: 'See the discussion'
}
Expand Down

0 comments on commit 1717936

Please sign in to comment.