From d030faf46c5622a6b08e2ebd8dcd7d34021ed5f3 Mon Sep 17 00:00:00 2001 From: Ekaterina Tuzova Date: Thu, 13 Apr 2017 12:07:43 +0300 Subject: [PATCH] load course lessons once --- .../com/jetbrains/edu/learning/stepic/EduStepicConnector.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/python/educational-core/src/com/jetbrains/edu/learning/stepic/EduStepicConnector.java b/python/educational-core/src/com/jetbrains/edu/learning/stepic/EduStepicConnector.java index 5ae616d81654..5e7726077452 100644 --- a/python/educational-core/src/com/jetbrains/edu/learning/stepic/EduStepicConnector.java +++ b/python/educational-core/src/com/jetbrains/edu/learning/stepic/EduStepicConnector.java @@ -217,6 +217,8 @@ public class EduStepicConnector { } public static RemoteCourse getCourse(@NotNull final Project project, @NotNull final RemoteCourse remoteCourse) { + final List lessons = remoteCourse.getLessons(true); + if (!lessons.isEmpty()) return remoteCourse; if (!remoteCourse.isAdaptive()) { try { for (Integer section : remoteCourse.getSections()) {