diff --git a/src/integrations/weatheralerts.ts b/src/integrations/weatheralerts.ts index de41453..b0fe980 100644 --- a/src/integrations/weatheralerts.ts +++ b/src/integrations/weatheralerts.ts @@ -110,12 +110,12 @@ export default class Weatheralerts implements MeteoalarmIntegration { alertLevel = level; const alertName = fullAlertName.replace(levelName, '').trim(); alertType = this.eventTypes[alertName]; - if(!alertType) { + if(alertType == undefined) { throw Error(`Unknown weatheralerts alert type: ${alertName}`); } } - if(!alertLevel) { + if(alertLevel == undefined) { throw Error(`Unknown weatheralerts alert level: ${fullAlertName}`); }