mirror of
https://github.com/billz/raspap-webgui.git
synced 2025-12-26 23:26:47 +01:00
Fix undefined vars in class methods + includes
This commit is contained in:
@@ -88,6 +88,7 @@ function DisplayDashboard(&$extraFooterScripts): void
|
||||
} else {
|
||||
$firewallManaged = '<a href="/plugin__Firewall">';
|
||||
$firewallStatus = ($dashboard->firewallEnabled() == true) ? "active" : "";
|
||||
$firewallUnavailable = null;
|
||||
}
|
||||
|
||||
echo renderTemplate(
|
||||
|
||||
@@ -49,7 +49,9 @@ function DisplayWireGuardConfig()
|
||||
exec('sudo cat '. RASPI_WIREGUARD_CONFIG, $return);
|
||||
$conf = ParseConfig($return, $parseFlag);
|
||||
$wg_srvpubkey = exec('sudo cat '. RASPI_WIREGUARD_PATH .'wg-server-public.key', $return);
|
||||
$wg_srvport = ($conf['ListenPort'] == '') ? getDefaultNetValue('wireguard','server','ListenPort') : $conf['ListenPort'];
|
||||
$wg_srvport = ($conf['ListenPort'] ?? '') === ''
|
||||
? getDefaultNetValue('wireguard','server','ListenPort')
|
||||
: $conf['ListenPort'];
|
||||
$wg_srvipaddress = ($conf['Address'] == '') ? getDefaultNetValue('wireguard','server','Address') : $conf['Address'];
|
||||
$wg_srvdns = ($conf['DNS'] == '') ? getDefaultNetValue('wireguard','server','DNS') : $conf['DNS'];
|
||||
if (is_array($wg_srvdns)) {
|
||||
|
||||
Reference in New Issue
Block a user