1
0
mirror of https://github.com/taigrr/wtf synced 2025-01-18 04:03:14 -08:00

Merge pull request #363 from wtfutil/362-firewall

362 Determine linux firewall status on the unambiguous term
This commit is contained in:
Chris Cummer 2019-01-25 15:18:25 -08:00 committed by GitHub
commit 85efb48f55
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -50,10 +50,10 @@ func firewallStateLinux() string { // might be very Ubuntu specific
return "[red]NA[white]"
}
if strings.Contains(o.String(), "active") {
return "[green]Enabled[white]"
} else {
if strings.Contains(o.String(), "inactive") {
return "[red]Disabled[white]"
} else {
return "[green]Enabled[white]"
}
} else {
return "[red]NA[white]"