parent
ea58b5a9c8
commit
c8a25e5d9a
9 changed files with 21 additions and 8 deletions
|
|
@ -13,7 +13,7 @@ const largeIcon = (link, _isNightTime) => {
|
|||
} catch (error) {
|
||||
console.warn(`largeIcon: ${error.message}`);
|
||||
// Return a fallback icon to prevent downstream errors
|
||||
return addPath(_isNightTime ? 'Clear.gif' : 'Sunny.gif');
|
||||
return addPath(`No-Data.gif?${conditionIcon}${isNightTime ? '-n' : ''}`);
|
||||
}
|
||||
|
||||
// find the icon
|
||||
|
|
@ -169,7 +169,7 @@ const largeIcon = (link, _isNightTime) => {
|
|||
default: {
|
||||
console.warn(`Unknown weather condition '${conditionIcon}' from ${link}; using fallback icon`);
|
||||
// Return a reasonable fallback instead of false to prevent downstream errors
|
||||
return addPath(isNightTime ? 'Clear.gif' : 'Sunny.gif');
|
||||
return addPath(`No-Data.gif?${conditionIcon}${isNightTime ? '-n' : ''}`);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue