Fix fixing courses with p1 and p2 notes

This commit is contained in:
KatieFrogs 2022-03-13 18:31:42 +03:00
parent ab3c421ab4
commit 7967ff1b09

View File

@ -67,13 +67,14 @@
if((name === "start" || name === "start p1") && !inSong){
inSong = true
if(!hasSong){
if(!hasSong || name === "start" && courses[courseName] && courses[courseName].startName !== "start"){
if(!(courseName in courses)){
courses[courseName] = {}
}
for(var name in currentCourse){
if(name !== "branch"){
courses[courseName][name] = currentCourse[name]
courses[courseName].startName = name
for(var opt in currentCourse){
if(opt !== "branch"){
courses[courseName][opt] = currentCourse[opt]
}
}
courses[courseName].start = lineNum + 1