[freeside-commits] branch FREESIDE_2_3_BRANCH updated. 226617fbfba28e74fb8175f6ce77a09302809128

Ivan ivan at 420.am
Wed Jun 20 02:45:30 PDT 2012


The branch, FREESIDE_2_3_BRANCH has been updated
       via  226617fbfba28e74fb8175f6ce77a09302809128 (commit)
      from  0bc8846f748977f897c35de1f227a45fd9ac7758 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 226617fbfba28e74fb8175f6ce77a09302809128
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Wed Jun 20 02:45:29 2012 -0700

    fix flat_introrate without an introductory period, RT#18124

diff --git a/FS/FS/part_pkg/flat_introrate.pm b/FS/FS/part_pkg/flat_introrate.pm
index 33cc3d4..10c2056 100644
--- a/FS/FS/part_pkg/flat_introrate.pm
+++ b/FS/FS/part_pkg/flat_introrate.pm
@@ -32,8 +32,8 @@ sub base_recur {
   warn "flat_introrate base_recur requires date!" if !$time;
   my $now = $time ? $$time : time;
 
-  my ($duration) = ($self->option('intro_duration') =~ /^(\d+)$/);
-  unless ($duration) {
+  my ($duration) = ($self->option('intro_duration') =~ /^\s*(\d+)\s*$/);
+  unless (length($duration)) {
     die "Invalid intro_duration: " . $self->option('intro_duration');
   }
   my $intro_end = $self->add_freq($cust_pkg->setup, $duration);

-----------------------------------------------------------------------

Summary of changes:
 FS/FS/part_pkg/flat_introrate.pm |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)




More information about the freeside-commits mailing list