Skip to content

Commit

Permalink
fix: Send screening missed message to pupil and not to the Screener (#…
Browse files Browse the repository at this point in the history
…954)

Co-authored-by: Jonas Wilms <[email protected]>
  • Loading branch information
Jonasdoubleyou and Jonas Wilms authored Jan 17, 2024
1 parent ff13439 commit 32cbb30
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion graphql/pupil/mutations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -339,8 +339,9 @@ export class MutatePupilResolver {
@Arg('comment') comment: string
): Promise<boolean> {
const screener = await getSessionScreener(context);
const { pupil } = await prisma.pupil_screening.findUniqueOrThrow({ where: { id: pupilScreeningId }, include: { pupil: true } });
await updatePupilScreening(screener, pupilScreeningId, { status: PupilScreeningStatus.pending, comment });
await Notification.actionTaken(userForScreener(screener), 'pupil_screening_missed', {});
await Notification.actionTaken(userForPupil(pupil), 'pupil_screening_missed', {});
return true;
}

Expand Down

0 comments on commit 32cbb30

Please sign in to comment.