Set numeric_version more globally so things like search don't break.
authorGreg Sabino Mullane <greg@users.mediawiki.org>
Sat, 22 Nov 2008 06:49:16 +0000 (06:49 +0000)
committerGreg Sabino Mullane <greg@users.mediawiki.org>
Sat, 22 Nov 2008 06:49:16 +0000 (06:49 +0000)
includes/db/DatabasePostgres.php

index deb1683..8b119e5 100644 (file)
@@ -205,7 +205,7 @@ class DatabasePostgres extends Database {
                global $wgDBname, $wgDBuser, $wgDBpassword, $wgDBsuperuser, $wgDBmwschema, $wgDBts2schema;
 
                print "<li>Checking the version of Postgres...";
-               $version = $this->numeric_version = $this->getServerVersion();
+               $version = $this->getServerVersion();
                $PGMINVER = '8.1';
                if ($version < $PGMINVER) {
                        print "<b>FAILED</b>. Required version is $PGMINVER. You have $version</li>\n";
@@ -1056,7 +1056,8 @@ class DatabasePostgres extends Database {
         */
        function getServerVersion() {
                $versionInfo = pg_version( $this->mConn );
-               return $versionInfo['server'];
+               $this->numeric_version = $versionInfo['server'];
+               return $this->numeric_version;
        }
 
        /**