Fix logic in single stat coloration getter
Sometimes results in a situation where coloration state gets set to a weird value, which seems to be a factor in the auto refresh bugpull/10616/head
parent
90b36ebc76
commit
1de16619be
|
@ -143,9 +143,11 @@ export const validateSingleStatColors = (colors, coloration) => {
|
||||||
export const getSingleStatColoration = colors => {
|
export const getSingleStatColoration = colors => {
|
||||||
if (!colors || colors.length === 0) {
|
if (!colors || colors.length === 0) {
|
||||||
return SINGLE_STAT_TEXT
|
return SINGLE_STAT_TEXT
|
||||||
|
} else if (colors[0].type === (SINGLE_STAT_TEXT || SINGLE_STAT_BG)) {
|
||||||
|
return colors[0].type
|
||||||
}
|
}
|
||||||
|
|
||||||
return colors[0].type
|
return SINGLE_STAT_TEXT
|
||||||
}
|
}
|
||||||
|
|
||||||
export const validateGaugeColors = colors => {
|
export const validateGaugeColors = colors => {
|
||||||
|
|
Loading…
Reference in New Issue