Apply automated PHP8 safety transforms

Agent-Logs-Url: https://github.com/GameServerPanel/GSP/sessions/89922108-1604-44ae-949d-358d32b9d70a

Co-authored-by: iaretechnician <2749183+iaretechnician@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-04-23 14:01:37 +00:00 committed by GitHub
parent aca850b6cd
commit e44519c030
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
465 changed files with 1716 additions and 1716 deletions

View file

@ -41,7 +41,7 @@ function exec_ogp_module()
if(!empty($_POST['gameserver_id']) && !empty($_POST['remote_server_id']) && !empty($_POST['gameserver_name'])
&& !empty($_POST['gameserver_ip']) && !empty($_POST['gameserver_port']) && !empty($_POST['addSteamid']) && !empty($_POST['sourcemod_perms'])){
foreach($servers as $server){
foreach ((array)$servers as $server){
// Try to check if hidden form values have been manually edited. If not, process.
if($server['remote_server_id'] == $_POST['remote_server_id'] && $server['home_id'] == $_POST['gameserver_id']
&& $server['game_name'] == $_POST['gameserver_name'] && $server['ip'] == $_POST['gameserver_ip'] && $server['port'] == $_POST['gameserver_port']){
@ -129,7 +129,7 @@ function exec_ogp_module()
}
}else{
$return = array();
for($x = 0; $x < count($servers); ++$x){
for($x = 0; $x < count((array)$servers); ++$x){
$return[] = array(
'remote_server_id' => $servers[$x]['remote_server_id'],
'ip' => $servers[$x]['ip'],