Prevent item-count-undefined

This commit is contained in:
Toby Zerner 2015-03-24 14:23:55 +10:30
parent b667c87090
commit e1fb1132da

View File

@ -19,7 +19,8 @@ export default Ember.Component.extend({
}), }),
itemCountClass: Ember.computed('items.length', function() { itemCountClass: Ember.computed('items.length', function() {
return 'item-count-'+this.get('items.length'); var count = this.get('items.length');
return count ? 'item-count-'+this.get('items.length') : '';
}), }),
actions: { actions: {