Improve code (#1976)
This commit is contained in:
parent
7c3955b2aa
commit
1a3ea8685e
|
@ -130,7 +130,7 @@ sub buildForm {
|
||||||
map {
|
map {
|
||||||
my ( $key, $value, $null ) = split '#', $_;
|
my ( $key, $value, $null ) = split '#', $_;
|
||||||
my @values = split $self->conf->{multiValuesSeparator},
|
my @values = split $self->conf->{multiValuesSeparator},
|
||||||
$self->conf->{findUserSearchingAttributes}->{$_} || $_;
|
$self->conf->{findUserSearchingAttributes}->{$_} || $key;
|
||||||
my $nbr = scalar @values;
|
my $nbr = scalar @values;
|
||||||
if ( $nbr > 1 ) {
|
if ( $nbr > 1 ) {
|
||||||
if ( $nbr % 2 ) { () }
|
if ( $nbr % 2 ) { () }
|
||||||
|
@ -155,9 +155,7 @@ sub buildForm {
|
||||||
{
|
{
|
||||||
select => 0,
|
select => 0,
|
||||||
key => $key,
|
key => $key,
|
||||||
value => $self->conf->{findUserSearchingAttributes}->{$_}
|
value => $values[0]
|
||||||
? $self->conf->{findUserSearchingAttributes}->{$_}
|
|
||||||
: $_
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
} sort keys %{ $self->conf->{findUserSearchingAttributes} };
|
} sort keys %{ $self->conf->{findUserSearchingAttributes} };
|
||||||
|
|
Loading…
Reference in New Issue
Block a user