code cleanup
This commit is contained in:
parent
019f9e1421
commit
bcedeaf5d5
2 changed files with 2 additions and 6 deletions
|
@ -29,7 +29,6 @@ import ch.ethz.seb.sebserver.gbl.util.Result;
|
||||||
import ch.ethz.seb.sebserver.webservice.servicelayer.dao.ConfigurationDAO;
|
import ch.ethz.seb.sebserver.webservice.servicelayer.dao.ConfigurationDAO;
|
||||||
import ch.ethz.seb.sebserver.webservice.servicelayer.dao.ExamConfigurationMapDAO;
|
import ch.ethz.seb.sebserver.webservice.servicelayer.dao.ExamConfigurationMapDAO;
|
||||||
import ch.ethz.seb.sebserver.webservice.servicelayer.dao.ExamDAO;
|
import ch.ethz.seb.sebserver.webservice.servicelayer.dao.ExamDAO;
|
||||||
import ch.ethz.seb.sebserver.webservice.servicelayer.exam.ExamAdminService;
|
|
||||||
import ch.ethz.seb.sebserver.webservice.servicelayer.session.ExamConfigUpdateService;
|
import ch.ethz.seb.sebserver.webservice.servicelayer.session.ExamConfigUpdateService;
|
||||||
import ch.ethz.seb.sebserver.webservice.servicelayer.session.ExamSessionService;
|
import ch.ethz.seb.sebserver.webservice.servicelayer.session.ExamSessionService;
|
||||||
|
|
||||||
|
@ -45,22 +44,19 @@ public class ExamConfigUpdateServiceImpl implements ExamConfigUpdateService {
|
||||||
private final ExamConfigurationMapDAO examConfigurationMapDAO;
|
private final ExamConfigurationMapDAO examConfigurationMapDAO;
|
||||||
private final ExamSessionService examSessionService;
|
private final ExamSessionService examSessionService;
|
||||||
private final ExamUpdateHandler examUpdateHandler;
|
private final ExamUpdateHandler examUpdateHandler;
|
||||||
private final ExamAdminService examAdminService;
|
|
||||||
|
|
||||||
protected ExamConfigUpdateServiceImpl(
|
protected ExamConfigUpdateServiceImpl(
|
||||||
final ExamDAO examDAO,
|
final ExamDAO examDAO,
|
||||||
final ConfigurationDAO configurationDAO,
|
final ConfigurationDAO configurationDAO,
|
||||||
final ExamConfigurationMapDAO examConfigurationMapDAO,
|
final ExamConfigurationMapDAO examConfigurationMapDAO,
|
||||||
final ExamSessionService examSessionService,
|
final ExamSessionService examSessionService,
|
||||||
final ExamUpdateHandler examUpdateHandler,
|
final ExamUpdateHandler examUpdateHandler) {
|
||||||
final ExamAdminService examAdminService) {
|
|
||||||
|
|
||||||
this.examDAO = examDAO;
|
this.examDAO = examDAO;
|
||||||
this.configurationDAO = configurationDAO;
|
this.configurationDAO = configurationDAO;
|
||||||
this.examConfigurationMapDAO = examConfigurationMapDAO;
|
this.examConfigurationMapDAO = examConfigurationMapDAO;
|
||||||
this.examSessionService = examSessionService;
|
this.examSessionService = examSessionService;
|
||||||
this.examUpdateHandler = examUpdateHandler;
|
this.examUpdateHandler = examUpdateHandler;
|
||||||
this.examAdminService = examAdminService;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// processing:
|
// processing:
|
||||||
|
|
|
@ -338,7 +338,7 @@ class ExamUpdateHandler {
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean hasChanges(final Exam exam, final QuizData quizData) {
|
private boolean hasChanges(final Exam exam, final QuizData quizData) {
|
||||||
if (!Objects.equals(exam.name, quizData.name) ||
|
if (Utils.isEqualsWithEmptyCheck(exam.name, quizData.name) ||
|
||||||
!Objects.equals(exam.startTime, quizData.startTime) ||
|
!Objects.equals(exam.startTime, quizData.startTime) ||
|
||||||
!Objects.equals(exam.endTime, quizData.endTime) ||
|
!Objects.equals(exam.endTime, quizData.endTime) ||
|
||||||
!Utils.isEqualsWithEmptyCheck(exam.getDescription(), quizData.description) ||
|
!Utils.isEqualsWithEmptyCheck(exam.getDescription(), quizData.description) ||
|
||||||
|
|
Loading…
Reference in a new issue