check for existing userinfo if settings are being imported via cli
Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
@@ -55,6 +55,7 @@ class IpAddr
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @return array
|
* @return array
|
||||||
|
* @throws \Exception
|
||||||
*/
|
*/
|
||||||
public static function getSslIpPortCombinations(): array
|
public static function getSslIpPortCombinations(): array
|
||||||
{
|
{
|
||||||
@@ -75,7 +76,7 @@ class IpAddr
|
|||||||
$additional_conditions_params = [];
|
$additional_conditions_params = [];
|
||||||
$additional_conditions_array = [];
|
$additional_conditions_array = [];
|
||||||
|
|
||||||
if ($userinfo['ip'] != '-1') {
|
if (!empty($userinfo) && $userinfo['ip'] != '-1') {
|
||||||
$admin_ip_stmt = Database::prepare("
|
$admin_ip_stmt = Database::prepare("
|
||||||
SELECT `id`, `ip`, `port` FROM `" . TABLE_PANEL_IPSANDPORTS . "` WHERE `id` = IN (:ipid)
|
SELECT `id`, `ip`, `port` FROM `" . TABLE_PANEL_IPSANDPORTS . "` WHERE `id` = IN (:ipid)
|
||||||
");
|
");
|
||||||
|
|||||||
Reference in New Issue
Block a user