mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
Improve the way the auth server list is generated and account for a key being removed from the array when deleting. Fixes #7682
This commit is contained in:
parent
7da9f1e5fe
commit
fa628b1a15
@ -139,10 +139,7 @@ if (!is_array($config['system']['authserver'])) {
|
||||
$config['system']['authserver'] = array();
|
||||
}
|
||||
|
||||
$a_servers = auth_get_authserver_list();
|
||||
foreach ($a_servers as $servers) {
|
||||
$a_server[] = $servers;
|
||||
}
|
||||
$a_server = array_values(auth_get_authserver_list());
|
||||
|
||||
if (!is_array($config['ca'])) {
|
||||
$config['ca'] = array();
|
||||
@ -171,6 +168,7 @@ if ($act == "del") {
|
||||
|
||||
/* Remove server from temp list used later on this page. */
|
||||
unset($a_server[$_GET['id']]);
|
||||
$a_server = array_values($a_server);
|
||||
|
||||
$savemsg = sprintf(gettext("Authentication Server %s deleted."), htmlspecialchars($serverdeleted));
|
||||
write_config($savemsg);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user