diff --git a/src/main/java/com/uniovi/services/QuestionGeneratorService.java b/src/main/java/com/uniovi/services/QuestionGeneratorService.java index 4f22f40f..d4e35327 100644 --- a/src/main/java/com/uniovi/services/QuestionGeneratorService.java +++ b/src/main/java/com/uniovi/services/QuestionGeneratorService.java @@ -68,6 +68,7 @@ private void parseQuestionTypes() throws IOException { @Scheduled(fixedRate = 86400000, initialDelay = 86400000) public void generateAllQuestions() throws IOException { + started = true; resetGeneration(); } @@ -78,7 +79,7 @@ public void generateQuestions() throws IOException, InterruptedException { return; } - if (started){ + if (started) { started = false; questionService.deleteAllQuestions(); }