mirror of
https://github.com/billz/raspap-webgui.git
synced 2025-07-07 23:07:39 +02:00
Fix: php7.4 compatibility
This commit is contained in:
parent
168ed2448f
commit
20fe5fc5a7
@ -26,12 +26,16 @@ class Dashboard {
|
||||
*/
|
||||
public function getVpnManged(?string $interface = null): ?string
|
||||
{
|
||||
return match ($interface) {
|
||||
'wg0' => '/wg_conf',
|
||||
'tun0' => '/openvpn_conf',
|
||||
'tailscale0' => '/plugin__Tailscale',
|
||||
default => null,
|
||||
};
|
||||
switch ($interface) {
|
||||
case 'wg0':
|
||||
return '/wg_conf';
|
||||
case 'tun0':
|
||||
return '/openvpn_conf';
|
||||
case 'tailscale0':
|
||||
return '/plugin__Tailscale';
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
x
Reference in New Issue
Block a user