Skip to content

Commit

Permalink
Don’t break search if list it empty. Closes #369
Browse files Browse the repository at this point in the history
  • Loading branch information
javve committed Feb 5, 2016
1 parent 8c1df3b commit d805494
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/search.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ module.exports = function(list) {
}
},
setColumns: function() {
if (list.items.length === 0) return;
if (columns === undefined) {
columns = (list.searchColumns === undefined) ? prepare.toArray(list.items[0].values()) : list.searchColumns;
}
Expand Down

0 comments on commit d805494

Please sign in to comment.