- my $all_units = scalar(@_) && (ref($_[0]) eq 'ARRAY') ? $_[0] : \@_;
- $all_units = SL::DB::Manager::Unit->get_all if !@{ $all_units };
+ my $all_units = scalar(@_) && (ref($_[0]) eq 'ARRAY') ? $_[0] : [ @_ ];
+ $all_units = SL::DB::Manager::Unit->all_units if ! @{ $all_units };