Skip to content

Commit

Permalink
ignore changes to the default branch on update
Browse files Browse the repository at this point in the history
  • Loading branch information
julian-christl committed Sep 13, 2023
1 parent 85ce04c commit 6a1e73a
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,9 @@ public ResponseEntity<ProgrammingExercise> updateProgrammingExercise(@RequestBod
// Forbid conversion between normal course exercise and exam exercise
exerciseService.checkForConversionBetweenExamAndCourseExercise(updatedProgrammingExercise, programmingExerciseBeforeUpdate, ENTITY_NAME);

// Ignore changes to the default branch
updatedProgrammingExercise.setBranch(programmingExerciseBeforeUpdate.getBranch());

if (updatedProgrammingExercise.getAuxiliaryRepositories() == null) {
// make sure the default value is set properly
updatedProgrammingExercise.setAuxiliaryRepositories(new ArrayList<>());
Expand Down

0 comments on commit 6a1e73a

Please sign in to comment.