Skip to content

Commit

Permalink
Update bot.php
Browse files Browse the repository at this point in the history
  • Loading branch information
wizwizdev authored May 2, 2024
1 parent 22e96fa commit fe9e85a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions bot.php
Original file line number Diff line number Diff line change
Expand Up @@ -6413,12 +6413,12 @@


$marzbanList = array_column($info, 0);
if(count($marzbanList) > 0) $condition = " AND `id` " .($userInfo['step'] == "addNewMarzbanPlan"?"IN":"NOT IN") . " (" . (str_repeat('?,', count($marzbanList) - 1) . '?') . ")";
if(count($marzbanList) > 0) $condition = " AND `id` " .($userInfo['step'] == "addNewMarzbanPlan"?"IN":"NOT IN") . " (" . implode(", ", $marzbanList) . ")";
else $condition = "";


$stmt = $connection->prepare("SELECT * FROM `server_info` WHERE `active`=1 $condition");
if(!empty($condition)) $stmt->execute($marzbanList);
else $stmt->execute();
$stmt->execute();

$srvs = $stmt->get_result();
$stmt->close();
Expand Down

0 comments on commit fe9e85a

Please sign in to comment.