From 0b722f3b62eef82181fa3cb92463fda7c808c18d Mon Sep 17 00:00:00 2001 From: Daniel Maya Date: Fri, 29 Jan 2021 14:02:35 +0100 Subject: [PATCH] Fixed master server --- pandora_console/godmode/servers/servers.build_table.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/pandora_console/godmode/servers/servers.build_table.php b/pandora_console/godmode/servers/servers.build_table.php index 3ca750c51b..d17d773b1d 100644 --- a/pandora_console/godmode/servers/servers.build_table.php +++ b/pandora_console/godmode/servers/servers.build_table.php @@ -79,6 +79,13 @@ if (check_acl($config['id_user'], 0, 'PM')) { $table->data = []; $names_servers = []; +$master = 1; +// The server with the highest number in master, will be the real master. +foreach ($servers as $server) { + if ($server['master'] > $master) { + $master = $server['master']; + } +} foreach ($servers as $server) { $data = []; @@ -109,7 +116,7 @@ foreach ($servers as $server) { // Type $data[2] = ''.$server['img']; - if ($server['master'] == 1) { + if ($server['master'] == $master) { $data[2] .= ui_print_help_tip(__('This is a master server'), true); }