Skip to content

Commit 209b5bb

Browse files
committed
Merge branch 'master' of github.com:gywgithub/vue-d3-examples
2 parents 380d588 + aefaba1 commit 209b5bb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/TreeVIII.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ export default {
253253
this.dialog = false
254254
if (this.currentNode.parent && this.currentNode.parent.children.length > 0) {
255255
this.currentNode.parent.children.filter((item, i) => {
256-
if (item.data && item.data.value === this.currentNode.data.value) {
256+
if (this.currentNode && item.data && item.data.value === this.currentNode.data.value) {
257257
this.currentNode.parent.children.splice(i, 1)
258258
if (this.currentNode.parent.children.length === 0) {
259259
delete this.currentNode.parent.children

0 commit comments

Comments
 (0)