Update locationdata_eu.py

This commit is contained in:
SpudGunMan
2024-12-18 19:24:33 -08:00
parent bd956dfebc
commit 6974c4ef66
+1 -2
View File
@@ -18,9 +18,8 @@ def get_govUK_alerts():
soup = bs.BeautifulSoup(response.text, 'html.parser')
# the alerts are in <h2 class="govuk-heading-m" id="alert-status">
alert = soup.find('h2', class_='govuk-heading-m', id='alert-status')
if alert:
return alert.text
return alert.get_text(strip=True)
else:
return "No alerts"