Skip to content
Snippets Groups Projects
Commit 28b280f8 authored by michael.minelli's avatar michael.minelli
Browse files

Assignment => Do not export corrections of unpublished assignment

parent 1cdc223a
No related branches found
No related tags found
No related merge requests found
......@@ -30,7 +30,7 @@ export default Prisma.defineExtension(client => {
assignment: {
corrections: {
compute(assignment) {
return new LazyVal<Array<Partial<Exercise>> | undefined>(() => getCorrections(assignment));
return new LazyVal<Array<Partial<Exercise>> | undefined>(() => assignment.published ? getCorrections(assignment) : []);
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment