Skip to content

Commit

Permalink
Fix #717: filter invalid colors
Browse files Browse the repository at this point in the history
  • Loading branch information
juliandescottes committed Jul 18, 2017
1 parent 96d326e commit a096dca
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/js/controller/PalettesListController.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@
var colors = this.getSelectedPaletteColors_();

if (colors.length > 0) {
var html = colors.map(function (color, index) {
var html = colors.filter(function (color) {
return !!color;
}).map(function (color, index) {
return pskl.utils.Template.replace(this.paletteColorTemplate_, {
color : color,
index : index + 1,
Expand Down

0 comments on commit a096dca

Please sign in to comment.