Guard against colors being passed in as an empty array

pull/10616/head
Alex P 2018-03-28 10:04:33 -07:00
parent 0146322629
commit a65b482419
1 changed files with 1 additions and 1 deletions

View File

@ -200,7 +200,7 @@ export const LINE_COLOR_SCALES = [
})
export const validateLineColors = colors => {
if (!colors) {
if (!colors || colors.length === 0) {
return DEFAULT_LINE_COLORS
}