Skip to content

Commit af703b4

Browse files
fix bugs
1 parent df51b08 commit af703b4

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

build/angular-cycle-gallery.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -407,6 +407,7 @@
407407
}
408408

409409
ItemsStorage.prototype.setItems = function(items) {
410+
if(!items){return;};
410411
this.count = items.length;
411412
this.items = items;
412413
this.cycler.setItems(this.items);

src/js/gallery/service/cycle_generator.coffee

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ angular.module('multiGallery').service 'CycleGenerator', ->
1313
_cycleItems: []
1414

1515
setItems: (items)->
16+
return unless items
1617
@_items = items
1718
@_count = items.length
1819
@_cycleItems = []

0 commit comments

Comments
 (0)