]> jfr.im git - irc/unrealircd/unrealircd-webpanel.git/blobdiff - users/index.php
Update unrealircd-admin.css
[irc/unrealircd/unrealircd-webpanel.git] / users / index.php
index 8cf714700e4bed8f8724928b55bfa2201e6f56ae..a520ae910b4b7425bda0ba2eb97e38ae0b72ed32 100644 (file)
@@ -17,13 +17,12 @@ if (!empty($_GET))
 if (!empty($_POST))
 {
        do_log($_POST);
-       $bantype = $_POST['bantype'];
+       $bantype = (isset($_POST['bantype'])) ? $_POST['bantype'] : NULL;
 
        if (isset($_POST['userch'])) {
                foreach ($_POST["userch"] as $user)
                {
                        $user = $name = base64_decode($user);
-                       $bantype = (isset($_POST['bantype'])) ? $_POST['bantype'] : NULL;
 
                        if (!$bantype) /* shouldn't happen? */
                        {
@@ -185,7 +184,7 @@ Click on a username to view more information.
                        echo "<th scope=\"row\"><input type=\"checkbox\" value='" . base64_encode($user->id)."' name=\"userch[]\"></th>";
                        $isBot = (strpos($user->user->modes, "B") !== false) ? ' <span class="badge rounded-pill badge-dark">Bot</span>' : "";
                        echo "<td><a href=\"details.php?nick=".$user->id."\">$user->name$isBot</a></td>";
-                       echo "<td>".htmlspecialchars($user->hostname)." (".htmlspecialchars($user->ip).")</td>";
+                       echo "<td>".htmlspecialchars($user->hostname)." (".htmlspecialchars($user->ip ?? "None").")</td>";
                        $account = (isset($user->user->account)) ? "<a href=\"".BASE_URL."users/?account=".$user->user->account."\">".htmlspecialchars($user->user->account)."</a>" : '<span class="badge rounded-pill badge-primary">None</span>';
                        echo "<td>".$account."</td>";
                        $modes = (isset($user->user->modes)) ? "+" . $user->user->modes : "<none>";