https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22461
--- Comment #21 from Jonathan Druart <[email protected]> --- Try that: use Koha::Patrons; my @columns = Koha::Patrons->columns; my $xxx = { cardnumber => 1, foo => 2, borrowernumber => 3, bar => 4, opacnote => undef }; my $h1 = { map { join(' ',@columns) =~ /$_/ ? ( $_ => $xxx->{$_} ) : () } keys(%$xxx) } ; # original version my $h2 = { map { defined( $xxx->{$_} ) ? ( $_ => $xxx->{$_} ) : () } @columns }; # new version use Data::Printer colored => 1; warn p $h1; use Data::Printer colored => 1; warn p $h2; Note sure if it is relevant however. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
