mirror of
https://github.com/billz/raspap-webgui.git
synced 2025-07-08 20:57:40 +02:00
Simplify getVpnManaged check with ternary operator
This commit is contained in:
parent
8d482845b0
commit
3d6b4e1f15
@ -74,9 +74,7 @@ function DisplayDashboard(&$extraFooterScripts): void
|
||||
$varName = "freq" . str_replace('.', '', $frequency) . "active";
|
||||
$$varName = "active";
|
||||
$vpnStatus = $vpn ? "active" : "inactive";
|
||||
if ($vpn) {
|
||||
$vpnManaged = $dashboard->getVpnManged($vpn);
|
||||
}
|
||||
$vpnManaged = $vpn ? $dashboard->getVpnManaged($vpn) : null;
|
||||
$firewallManaged = $firewallStatus = "";
|
||||
$firewallInstalled = array_filter($plugins, fn($p) => str_ends_with($p, 'Firewall')) ? true : false;
|
||||
if (!$firewallInstalled) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user