From 6e4a1afd9ef94fc28ef6739b9ce7b3c5b5934579 Mon Sep 17 00:00:00 2001 From: anhefti Date: Tue, 3 May 2022 10:37:32 +0200 Subject: [PATCH] fixed possible double default exam template on creation --- .../webservice/servicelayer/dao/impl/ExamTemplateDAOImpl.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/dao/impl/ExamTemplateDAOImpl.java b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/dao/impl/ExamTemplateDAOImpl.java index da0eed2a..554db721 100644 --- a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/dao/impl/ExamTemplateDAOImpl.java +++ b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/dao/impl/ExamTemplateDAOImpl.java @@ -185,6 +185,7 @@ public class ExamTemplateDAOImpl implements ExamTemplateDAO { return Result.tryCatch(() -> { checkUniqueName(data); + checkUniqueDefault(data); final Collection indicatorTemplates = data.getIndicatorTemplates(); final String indicatorsJSON = (indicatorTemplates != null && !indicatorTemplates.isEmpty())