Skip to content

Commit

Permalink
fix color formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
mattkime committed Dec 4, 2020
1 parent 4915a8d commit f30aca7
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ export class ColorFormatEditor extends DefaultFormatEditor<ColorFormatEditorForm
};

addColor = () => {
const colors = [...this.props.formatParams.colors];
const colors = [...(this.props.formatParams.colors || [])];
this.onChange({
colors: [...colors, { ...fieldFormats.DEFAULT_CONVERTER_COLOR }],
});
Expand Down

0 comments on commit f30aca7

Please sign in to comment.