diff --git a/app.py b/app.py index c5f818a..b9ac139 100644 --- a/app.py +++ b/app.py @@ -98,9 +98,14 @@ def send_notification(alert_level, avg_pm25, avg_pm10, avg_pm1): ) else: emoji = EMOJIS[alert_level] - alert_text = "podwyższony" if alert_level == 1 else "wysoki" + if alert_level == 1: + alert_text = "podwyższony" + elif alert_level == 2: + alert_text = "wysoki" + elif alert_level == 3: + alert_text = "bardzo wysoki" message = ( - f"{emoji} Uwaga! {alert_text.capitalize()} poziom zanieczyszczeń:\n" + f"{emoji} Uwaga! Wzrost poziomu zanieczyszczeń! Aktualnie poziom zanieczyszczenia jest {alert_text}.\n" f"PM2.5: {avg_pm25:.2f} µg/m3\n" f"PM10: {avg_pm10:.2f} µg/m3\n" f"PM1: {avg_pm1:.2f} µg/m3\n"