diff --git a/NodeApp/src/commander/exercise/subcommands/ExerciseCorrectionCommand.ts b/NodeApp/src/commander/exercise/subcommands/ExerciseCorrectionCommand.ts index 6dfddd1a4eed2f39a8ae2def689536d4b9275bdf..5e6310b214c162fa585584c4c3e46a61aab96595 100644 --- a/NodeApp/src/commander/exercise/subcommands/ExerciseCorrectionCommand.ts +++ b/NodeApp/src/commander/exercise/subcommands/ExerciseCorrectionCommand.ts @@ -39,8 +39,10 @@ class ExerciseCorrectionCommand extends CommanderCommand { private getCorrections(assignment: Assignment): Array<CorrectionResume> { return assignment.corrections.map(correction => { + const authors = correction.name.replace(correction.assignmentName, '').split('-')[2].trim(); + return { - name : correction.name.replace(correction.assignmentName, '').split('-')[2].trim(), + name : (correction.correctionDescription && correction.correctionDescription != '' ? `${ correction.correctionDescription } (${ authors })` : authors), value: correction.correctionCommit?.web_url?.replace('/commit/', '/tree/') ?? '' }; });