2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-06-13 09:50:19 +00:00

Stop repeating domains in domain-search

Fixes issue #246.
This commit is contained in:
loz-hurst
2015-10-08 14:50:17 +01:00
parent 97b6c4cbe8
commit 315a7fb841

View File

@ -1490,9 +1490,9 @@ sub process_request
# - include the site domain - if any
my $nettab = xCAT::Table->new("networks");
my @doms = $nettab->getAllAttribs('domain');
foreach(@doms){
if ($_->{domain}) {
push (@alldomains, $_->{domain});
foreach my $netdom (@doms){
if ($netdom->{domain}) {
push (@alldomains, $netdom->{domain}) unless grep(/^$netdom->{domain}$/, @alldomains);
}
}
$nettab->close;