From d880bb65414c7f619abac6215eedbbdd75e5cf84 Mon Sep 17 00:00:00 2001 From: Nicolas Vigier Date: Sun, 12 May 2013 14:58:16 +0000 Subject: mga-treasurer: use two digits for month git-svn-id: svn+ssh://svn.mageia.org/svn/soft/mga-treasurer/trunk@8210 5b7c3c08-40e5-403b-9995-ace06908e4af --- mga-treasurer | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mga-treasurer b/mga-treasurer index bc06e3c..1efe831 100755 --- a/mga-treasurer +++ b/mga-treasurer @@ -68,7 +68,7 @@ sub donations_infos { ); foreach my $don (@{$res{donations}}) { my $dt = DateTime->from_epoch(epoch => $don->{date}); - my $month = $dt->year . '-' . $dt->month; + my $month = $dt->year . '-' . sprintf("%02d", $dt->month); my $year = $dt->year; push @{$res{by_month}->{$month}->{donations}}, $don; $res{by_month}->{$month}->{year} = $year; -- cgit v1.2.1