TT#69200 Use none() instead of comparin $mode with each value

Change-Id: Ib13f0ff01e9665feabb78aac08c14e5276c08cf7
changes/62/35062/1
Guillem Jover 6 years ago
parent f5921964d3
commit c5522cdc8b

@ -3,7 +3,7 @@ use strict;
## no critic
use List::Util qw(any uniq);
use List::Util qw(any none uniq);
use NGCP::BulkProcessor::Table;
@ -256,7 +256,7 @@ sub array_to_map {
$get_value_code = sub { return shift; };
}
$mode = lc $mode;
if (not ($mode eq 'group' or $mode eq 'first' or $mode eq 'last')) {
if (none { $mode eq $_ } qw(group first last)) {
$mode = 'group';
}
foreach my $item (@{$array_ptr}) {

Loading…
Cancel
Save