Ignore empty alerts

This commit is contained in:
Tim Wilkinson 2022-01-20 17:12:00 -08:00 committed by Joe AE6XE
parent 9a8c1fd68f
commit 160af18978
1 changed files with 2 additions and 2 deletions

View File

@ -80,10 +80,10 @@ function html.alert_banner()
html.print("<div style=\"padding:5px;background-color:yellow;color:black;border:1px solid #ccc;width:600px;\"><a href=\"/cgi-bin/sysinfo.lua\">!!!! UNTESTED HARDWARE !!!!</a></div>") html.print("<div style=\"padding:5px;background-color:yellow;color:black;border:1px solid #ccc;width:600px;\"><a href=\"/cgi-bin/sysinfo.lua\">!!!! UNTESTED HARDWARE !!!!</a></div>")
end end
if aredn_message then if aredn_message and #aredn_message > 0 then
html.print("<div style=\"padding:5px;background-color:#fff380;color:black;border:1px solid #ccc;width:600px;\"><strong>AREDN Alert(s):</strong><br /><div style=\"text-align:left;\">" .. aredn_message .. "</div></div>") html.print("<div style=\"padding:5px;background-color:#fff380;color:black;border:1px solid #ccc;width:600px;\"><strong>AREDN Alert(s):</strong><br /><div style=\"text-align:left;\">" .. aredn_message .. "</div></div>")
end end
if local_message then if local_message and #local_message > 0 then
html.print("<div style=\"padding:5px;background-color:#fff380;color:black;border:1px solid #ccc;width:600px;\"><strong>Local Alert(s):</strong><br /><div style=\"text-align:left;\">" .. local_message .. "</div></div>") html.print("<div style=\"padding:5px;background-color:#fff380;color:black;border:1px solid #ccc;width:600px;\"><strong>Local Alert(s):</strong><br /><div style=\"text-align:left;\">" .. local_message .. "</div></div>")
end end