[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Omaha.pm] we need a 1 liner




Can anyone tell me what the 1 liner for this is before Andy does?

:)

j


 my @old = @{$self->{pools}};
 my @new;
 foreach (@old) {
    if (@$_ > 0) {
       push @new, $_;
    }
 }
 $self->{pools} = \@new;