continue;
}
- print "<li>Connected to $myver";
+ print "<li>Connected to {$conf->DBtype} $myver";
if ($conf->DBtype == 'mysql') {
if( version_compare( $myver, "4.0.14" ) < 0 ) {
print "</li>\n";
$wgDatabase->selectDB( $wgDBname );
}
else if ($conf->DBtype == 'postgres') {
- if( version_compare( $myver, "PostgreSQL 8.0" ) < 0 ) {
+ if( version_compare( $myver, "8.0" ) < 0 ) {
dieout( "<b>Postgres 8.0 or later is required</b>. Aborting." );
}
}
*/
function getServerVersion() {
$versionInfo = pg_version( $this->mConn );
- $this->numeric_version = $versionInfo['server'];
+ if ( isset( $versionInfo['server'] ) ) {
+ $this->numeric_version = $versionInfo['server'];
+ } else {
+ // There's no way to identify the precise version before 7.4, but
+ // it doesn't matter anyway since we're just going to give an error.
+ $this->numeric_version = '7.3 or earlier';
+ }
return $this->numeric_version;
}