From cb0c47fff7f412d2a8f9ae611f84584fcf8518de Mon Sep 17 00:00:00 2001 From: Ivan Kohler Date: Thu, 11 Oct 2012 15:57:39 -0700 Subject: [PATCH] fix overage billing with multiple exports? RT#19595 --- FS/FS/part_svc.pm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/FS/FS/part_svc.pm b/FS/FS/part_svc.pm index 7f22411e0..c47177171 100644 --- a/FS/FS/part_svc.pm +++ b/FS/FS/part_svc.pm @@ -441,9 +441,10 @@ sub part_export { my $self = shift; my %search; $search{'exporttype'} = shift if @_; - sort { $a->weight <=> $b->weight } - map { qsearchs('part_export', { 'exportnum' => $_->exportnum, %search } ) } - qsearch('export_svc', { 'svcpart' => $self->svcpart } ); + map { $_ } #behavior of sort undefined in scalar context + sort { $a->weight <=> $b->weight } + map { qsearchs('part_export', { 'exportnum'=>$_->exportnum, %search } ) } + qsearch('export_svc', { 'svcpart'=>$self->svcpart } ); } =item part_export_usage -- 2.11.0