From f8706d26d4c4849eecdec0b25ef437b90c1c3cd6 Mon Sep 17 00:00:00 2001 From: anhefti Date: Mon, 2 Oct 2023 15:53:31 +0200 Subject: [PATCH] fixed exam id change check --- .../servicelayer/session/impl/ExamUpdateHandler.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamUpdateHandler.java b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamUpdateHandler.java index 1ab751a3..55b1d1c5 100644 --- a/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamUpdateHandler.java +++ b/src/main/java/ch/ethz/seb/sebserver/webservice/servicelayer/session/impl/ExamUpdateHandler.java @@ -357,7 +357,7 @@ class ExamUpdateHandler { !Objects.equals(exam.endTime, quizData.endTime) || !Utils.isEqualsWithEmptyCheckTruncated(exam.getDescription(), quizData.description) || !Utils.isEqualsWithEmptyCheck(exam.getStartURL(), quizData.startURL) || - !exam.externalId.equals(quizData.id)) { + !Objects.equals(exam.externalId, quizData.id)) { if (!Utils.isEqualsWithEmptyCheck(exam.name, quizData.name)) { log.info("Update name difference from LMS. Exam: {}, QuizData: {}", exam.name, quizData.name); @@ -377,7 +377,7 @@ class ExamUpdateHandler { exam.getStartURL(), quizData.startURL); } - if (exam.externalId.equals(quizData.id)) { + if (!Objects.equals(exam.externalId, quizData.id)) { log.info("Update quizId difference from LMS. Exam:{}, QuizData: {}", exam.externalId, quizData.id);