From a4ebb5b4e20d1b7c41332268661313a3e5280597 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20K=C3=B6nig?= Date: Mon, 6 Jun 2022 10:33:53 +0200 Subject: [PATCH] Remove unnecessary else case MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Christian König --- settings.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/settings.php b/settings.php index 1c1969cee..31eb9de13 100644 --- a/settings.php +++ b/settings.php @@ -80,10 +80,8 @@ // get the gateway address for the default route on the Pi-hole interface if ($piHoleInterface !== "unknown") { $IPv4GW=shell_exec("ip -4 route | grep default | grep '${piHoleInterface}' | cut -d ' ' -f 3"); -} else { - $IPv4GW = "unknown"; } -// if the route did not return anything +// if the route did not return anything or $piHoleInterface is unknown if (empty($IPv4GW)) { $IPv4GW = "unknown"; }