From 5f08e16d4ccc930ad22f53800cd09a4d0e0a7867 Mon Sep 17 00:00:00 2001 From: tetragon Date: Mon, 7 May 2007 21:19:32 +0000 Subject: Scope fixing and a bugfix for $form->add_date git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@1160 4979c152-3d1c-0410-bac9-87ea11338e46 --- LedgerSMB/Form.pm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'LedgerSMB/Form.pm') diff --git a/LedgerSMB/Form.pm b/LedgerSMB/Form.pm index 5771e124..b8a23b01 100644 --- a/LedgerSMB/Form.pm +++ b/LedgerSMB/Form.pm @@ -1376,6 +1376,9 @@ sub add_date { my $diff = 0; my $spc = $myconfig->{dateformat}; + my $yy; + my $mm; + my $dd; $spc =~ s/\w//g; $spc = substr( $spc, 0, 1 ); @@ -1399,7 +1402,7 @@ sub add_date { else { # ISO - ( $yy, $mm, $dd ) =~ /(....)(..)(..)/; + ( $yy, $mm, $dd ) = ($date =~ /(....)(..)(..)/); } if ( $unit eq 'days' ) { -- cgit v1.2.3