projects
/
clearscm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
411571a
)
Fixed error in date handling.
author
Andrew DeFaria
<Andrew@DeFaria.com>
Sun, 5 Nov 2017 03:13:07 +0000
(20:13 -0700)
committer
Andrew DeFaria
<Andrew@DeFaria.com>
Sun, 5 Nov 2017 03:13:07 +0000
(20:13 -0700)
maps/bin/MAPSUtil.pm
patch
|
blob
|
history
diff --git
a/maps/bin/MAPSUtil.pm
b/maps/bin/MAPSUtil.pm
index
2298d77
..
e28a9d6
100644
(file)
--- a/
maps/bin/MAPSUtil.pm
+++ b/
maps/bin/MAPSUtil.pm
@@
-33,9
+33,9
@@
sub Today2SQLDatetime;
sub FormatDate {
my ($date) = @_;
sub FormatDate {
my ($date) = @_;
- return substr
$date, 5, 2
. '/' .
- substr
$date, 8, 2
. '/' .
- substr
$date, 0, 4
;
+ return substr
($date, 5, 2)
. '/' .
+ substr
($date, 8, 2)
. '/' .
+ substr
($date, 0, 4)
;
} # FormatDate
sub FormatTime {
} # FormatDate
sub FormatTime {
@@
-141,9
+141,9
@@
sub SubtractDays {
$month = '0' . $month;
} # if
$month = '0' . $month;
} # if
- # Prefix days with
0 if necessary
- if ($days
eq
0) {
-
$days = '01';
+ # Prefix days with 0 if necessary
+ if ($days
==
0) {
+ $days = '01';
} elsif ($days < 10) {
$days = '0' . $days;
} # if
} elsif ($days < 10) {
$days = '0' . $days;
} # if