projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bb70ee9
)
"1 months", eww
author
Mark Wells
<mark@freeside.biz>
Tue, 8 Sep 2015 00:40:25 +0000
(17:40 -0700)
committer
Mark Wells
<mark@freeside.biz>
Tue, 8 Sep 2015 00:40:25 +0000
(17:40 -0700)
FS/FS/discount.pm
patch
|
blob
|
history
diff --git
a/FS/FS/discount.pm
b/FS/FS/discount.pm
index
361e0b4
..
e113357
100644
(file)
--- a/
FS/FS/discount.pm
+++ b/
FS/FS/discount.pm
@@
-196,7
+196,13
@@
sub description {
( my $months = $self->months ) =~ s/\.0+$//;
$months =~ s/(\.\d*[1-9])0+$/$1/;
- $desc .= " for $months months" if $months;
+ if ($months) {
+ if ($months == 1) {
+ $desc .= " for 1 month";
+ } else {
+ $desc .= " for $months months";
+ }
+ }
$desc .= ', applies to setup' if $self->setup;