Jelajahi Sumber

暂时不比较嵌套数组

QuKatie 3 tahun lalu
induk
melakukan
db911e5864
1 mengubah file dengan 4 tambahan dan 2 penghapusan
  1. 4 2
      src/util/contrastData.js

+ 4 - 2
src/util/contrastData.js

@@ -25,8 +25,10 @@ export function contrastList(newlist, oldlist) {
           delete oldlist[i].olditem
         }
         if (newitem == olditem) {
-          if (newlist[i][newitem] != oldlist[i][olditem]) {
-            return true
+          if(!(newlist[i][newitem] instanceof Array)){
+            if (newlist[i][newitem] != oldlist[i][olditem]) {
+              return true
+            }
           }
         }
       }