Skip to content

Commit

Permalink
Fix permission problem
Browse files Browse the repository at this point in the history
  • Loading branch information
rpadovani authored and Stephan Krusche committed Apr 23, 2019
1 parent 8790c8e commit e7397b9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ public ResponseEntity<ExampleSubmission> getExampleSubmission(@PathVariable Long
Optional<ExampleSubmission> exampleSubmission = exampleSubmissionService.getWithEagerExercise(id);

if (exampleSubmission.isPresent()) {
if (!authCheckService.isAtLeastInstructorForExercise(exampleSubmission.get().getExercise())) {
if (! authCheckService.isAtLeastTeachingAssistantForExercise(exampleSubmission.get().getExercise())) {
return forbidden();
}
}
Expand Down

0 comments on commit e7397b9

Please sign in to comment.