X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fsvc_Tower_Mixin.pm;h=3da07c1cd0d3e3b5d812bf902dabcbd859d0302c;hb=3564f619654c5cbf22fc2acbe7eff0c08308e859;hp=0b558846610a2cf89fec496cc51944e15087eb10;hpb=5697bba078d6f9e263775bc2d887cc1ce3ff873d;p=freeside.git diff --git a/FS/FS/svc_Tower_Mixin.pm b/FS/FS/svc_Tower_Mixin.pm index 0b5588466..3da07c1cd 100644 --- a/FS/FS/svc_Tower_Mixin.pm +++ b/FS/FS/svc_Tower_Mixin.pm @@ -27,12 +27,10 @@ towernum or sectornum can also contain 'none' to allow null values. =cut sub tower_sector_sql { - my $class = shift; - my $params = shift; - return '' unless keys %$params; - my $where = ''; + my( $class, $params ) = @_; + return () unless keys %$params; - my @where; + my @where = (); for my $field (qw(towernum sectornum)) { my $value = $params->{$field} or next; if ( ref $value and grep { $_ } @$value ) { @@ -52,5 +50,4 @@ sub tower_sector_sql { @where; } - 1;