lsc преди 2 години
родител
ревизия
df8122cd9c
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      src/components/pages/addCourse.vue

+ 1 - 1
src/components/pages/addCourse.vue

@@ -4489,7 +4489,7 @@ export default {
 
           for (let i = 0; i < unitJson.length; i++) {
             if (
-              i < _unitJson.length - 1 &&
+              (i < _unitJson.length - 1 || i == _unitJson.length - 1) &&
               _unitJson[i].chapterInfo[0].chapterid !=
                 unitJson[i].chapterInfo[0].chapterid
             ) {