mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-11-27 09:35:39 -05:00
🐛/courses wd2 Start button goes to wrong level
We can’t cache course instance sessions by course because of web dev primer levels and classroom versioning.
This commit is contained in:
parent
527ba277ab
commit
df69cb54a8
1 changed files with 1 additions and 5 deletions
|
@ -68,13 +68,9 @@ module.exports = class CoursesView extends RootView
|
|||
@onClassLoadError()
|
||||
|
||||
onCourseInstancesLoaded: ->
|
||||
map = {}
|
||||
for courseInstance in @courseInstances.models
|
||||
courseID = courseInstance.get('courseID')
|
||||
if map[courseID]
|
||||
courseInstance.sessions = map[courseID]
|
||||
continue
|
||||
map[courseID] = courseInstance.sessions = new CocoCollection([], {
|
||||
courseInstance.sessions = new CocoCollection([], {
|
||||
url: courseInstance.url() + '/my-course-level-sessions',
|
||||
model: LevelSession
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue