fix: color retrieval

This commit is contained in:
Josh Moore 2023-09-30 01:01:31 -06:00
parent 35e2e08708
commit 16c5d959ff
1 changed files with 1 additions and 1 deletions

View File

@ -51,7 +51,7 @@ export function randomHexColour() { // From: https://www.geeksforgeeks.org/javas
}
export function getResourceColor(colorValue: string, vibrantValue: string) {
return colorValue === '&random' ? randomHexColour() : colorValue === '&vibrant' ? vibrantValue : colorValue;
return (!colorValue || colorValue === '&vibrant') ? vibrantValue : colorValue === '&random' ? randomHexColour() : colorValue;
}
export function formatTimestamp(timestamp: number, timeoffset: string) {