Skip to content

Commit 0a5a10c

Browse files
Fix regression when slots are undefined
1 parent 003a97b commit 0a5a10c

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

dist/vuedraggable.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,11 +121,11 @@ function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr
121121
this.transitionMode = true;
122122
}
123123
}
124-
var children = [].concat(_toConsumableArray(slots));
124+
var children = slots;
125125
var footer = this.$slots.footer;
126126

127127
if (footer) {
128-
children = [].concat(_toConsumableArray(slots), _toConsumableArray(footer));
128+
children = slots ? [].concat(_toConsumableArray(slots), _toConsumableArray(footer)) : [].concat(_toConsumableArray(footer));
129129
}
130130
return h(this.element, null, children);
131131
},

dist/vuedraggable.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/dist/vuedraggable.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,11 +121,11 @@ function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr
121121
this.transitionMode = true;
122122
}
123123
}
124-
var children = [].concat(_toConsumableArray(slots));
124+
var children = slots;
125125
var footer = this.$slots.footer;
126126

127127
if (footer) {
128-
children = [].concat(_toConsumableArray(slots), _toConsumableArray(footer));
128+
children = slots ? [].concat(_toConsumableArray(slots), _toConsumableArray(footer)) : [].concat(_toConsumableArray(footer));
129129
}
130130
return h(this.element, null, children);
131131
},

0 commit comments

Comments
 (0)