From f9fe13f32247abde25f6da166ebaca016acc3e79 Mon Sep 17 00:00:00 2001 From: SpudGunMan Date: Fri, 20 Dec 2024 21:22:21 -0800 Subject: [PATCH] Update system.py --- modules/system.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/modules/system.py b/modules/system.py index 7ed6425..49f4115 100644 --- a/modules/system.py +++ b/modules/system.py @@ -674,9 +674,17 @@ def handleAlertBroadcast(deviceID=1): if clock.second > 17: return False + # check for alerts - alertWx = alertBrodcastNOAA() - alertFema = getIpawsAlert(latitudeValue,longitudeValue, shortAlerts=True) + if wxAlertBroadcastEnabled: + alertWx = alertBrodcastNOAA() + else: + alertWx = NO_ALERTS + + if emergencyAlertBrodcastEnabled: + alertFema = getIpawsAlert(latitudeValue,longitudeValue, shortAlerts=True) + else: + alertFema = NO_ALERTS if enableGBalerts: alertUk = get_govUK_alerts()