diff --git a/src/RaspAP/Networking/Hotspot/DhcpcdManager.php b/src/RaspAP/Networking/Hotspot/DhcpcdManager.php index 9e397112..50fc9433 100644 --- a/src/RaspAP/Networking/Hotspot/DhcpcdManager.php +++ b/src/RaspAP/Networking/Hotspot/DhcpcdManager.php @@ -1,12 +1,19 @@ + * @license https://github.com/raspap/raspap-webgui/blob/master/LICENSE + */ + +declare(strict_types=1); + namespace RaspAP\Networking\Hotspot; use RaspAP\Messages\StatusMessage; -/** - * Handles dhcpcd.conf interface configuration. - */ class DhcpcdManager { private const CONF_DEFAULT = RASPI_DHCPCD_CONFIG; @@ -99,6 +106,7 @@ class DhcpcdManager ); } $dhcp_cfg = file_get_contents(SELF::CONF_DEFAULT); + $skip_dhcp = false; if (preg_match('/wlan[3-9]\d*|wlan[1-9]\d+/', $ap_iface)) { $skip_dhcp = true; @@ -280,8 +288,7 @@ class DhcpcdManager $lines = []; exec('cat ' . escapeshellarg($dnsmasqFile), $lines); if (!function_exists('ParseConfig')) { - // ensure legacy parser available - require_once RASPI_CONFIG . '/functions.php'; + require_once 'includes/functions.php'; } $conf = ParseConfig($lines); diff --git a/src/RaspAP/Networking/Hotspot/DnsmasqManager.php b/src/RaspAP/Networking/Hotspot/DnsmasqManager.php index 94a45803..0b4cd81b 100644 --- a/src/RaspAP/Networking/Hotspot/DnsmasqManager.php +++ b/src/RaspAP/Networking/Hotspot/DnsmasqManager.php @@ -1,7 +1,5 @@ * @license https://github.com/raspap/raspap-webgui/blob/master/LICENSE */ + +declare(strict_types=1); + +namespace RaspAP\Networking\Hotspot\Validators; + +use RaspAP\Messages\StatusMessage; + class HostapdValidator { diff --git a/src/RaspAP/Networking/Hotspot/WiFiManager.php b/src/RaspAP/Networking/Hotspot/WiFiManager.php index 4e2e4a9f..bc07fe1d 100644 --- a/src/RaspAP/Networking/Hotspot/WiFiManager.php +++ b/src/RaspAP/Networking/Hotspot/WiFiManager.php @@ -1,14 +1,16 @@ * @license https://github.com/raspap/raspap-webgui/blob/master/LICENSE */ +declare(strict_types=1); + +namespace RaspAP\Networking\Hotspot; + class WiFiManager {