fixed extra warning during install.pl
authorGalen Charlton <galen.charlton@liblime.com>
Wed, 31 Oct 2007 18:38:04 +0000 (13:38 -0500)
committerJoshua Ferraro <jmf@liblime.com>
Thu, 1 Nov 2007 00:45:09 +0000 (19:45 -0500)
Signed-off-by: Chris Cormack <crc@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
installer/install.pl

index a587249..c210a04 100755 (executable)
@@ -599,10 +599,10 @@ elsif ( $step && $step == 3 ) {
             # if there is, then we just need to upgrade
             # if there is none, then we need to install the database
             #
-            my $dbversion = C4::Context->preference('Version');
-            $dbversion =~ /(.*)\.(..)(..)(...)/;
-            $dbversion = "$1.$2.$3.$4";
             if (C4::Context->preference('Version')) {
+                my $dbversion = C4::Context->preference('Version');
+                $dbversion =~ /(.*)\.(..)(..)(...)/;
+                $dbversion = "$1.$2.$3.$4";
                 $template->param("upgrading" => 1,
                                 "dbversion" => $dbversion,
                                 "kohaversion" => C4::Context->KOHAVERSION,