Skip to content

Commit bc2f369

Browse files
committed
fix candidate viewed by client notification
1 parent 01e8e02 commit bc2f369

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/services/JobCandidateService.js

+2-3
Original file line numberDiff line numberDiff line change
@@ -370,15 +370,14 @@ async function downloadJobCandidateResume (currentUser, id) {
370370
const { id: currentUserUserId } = await helper.getUserByExternalId(currentUser.userId)
371371

372372
// customer role
373-
if (!jobCandidate.viewedByCustomer && currentUserUserId !== jobCandidate.userId && currentUser.roles.length === 1 && currentUser.roles[0] === UserRoles.TopcoderUser) {
373+
if (currentUserUserId !== jobCandidate.userId && currentUser.roles.length === 1 && currentUser.roles[0] === UserRoles.TopcoderUser) {
374374
try {
375375
const job = await models.Job.findById(jobCandidate.jobId)
376376
const { handle } = await helper.getUserById(jobCandidate.userId, true)
377-
const { email } = await helper.getMemberDetailsByHandle(handle)
378377

379378
await NotificationSchedulerService.sendNotification(currentUser, {
380379
template: 'taas.notification.job-candidate-resume-viewed',
381-
recipients: [email],
380+
recipients: [{ handle }],
382381
data: {
383382
jobCandidateUserHandle: handle,
384383
jobName: job.title,

0 commit comments

Comments
 (0)