From a5947f6e870cca34b4a7e1a627ff3277b3a54296 Mon Sep 17 00:00:00 2001 From: Chad Horohoe Date: Wed, 10 Nov 2010 16:06:42 +0000 Subject: [PATCH] Drop setup_database() here too. Only caller is the old installer --- includes/db/DatabaseSqlite.php | 30 ------------------------------ 1 file changed, 30 deletions(-) diff --git a/includes/db/DatabaseSqlite.php b/includes/db/DatabaseSqlite.php index 3a9a171d80..af00b04117 100644 --- a/includes/db/DatabaseSqlite.php +++ b/includes/db/DatabaseSqlite.php @@ -538,36 +538,6 @@ class DatabaseSqlite extends DatabaseBase { return parent::buildLike( $params ) . "ESCAPE '\' "; } - /** - * Called by the installer script - * - this is the same way PostgreSQL works, MySQL reads in tables.sql and interwiki.sql using DatabaseBase::sourceFile() - */ - public function setup_database() { - global $IP; - - # Process common MySQL/SQLite table definitions - $err = $this->sourceFile( "$IP/maintenance/tables.sql" ); - if ( $err !== true ) { - echo " FAILED"; - dieout( htmlspecialchars( $err ) ); - } - echo " done."; - - # Use DatabasePostgres's code to populate interwiki from MySQL template - $f = fopen( "$IP/maintenance/interwiki.sql", 'r' ); - if ( !$f ) { - dieout( "Could not find the interwiki.sql file." ); - } - - $sql = "INSERT INTO interwiki(iw_prefix,iw_url,iw_local,iw_api,iw_wikiid) VALUES "; - while ( !feof( $f ) ) { - $line = fgets( $f, 1024 ); - $matches = array(); - if ( !preg_match( '/^\s*(\(.+?),(\d)\)/', $line, $matches ) ) continue; - $this->query( "$sql $matches[1],$matches[2],'','')" ); - } - } - public function getSearchEngine() { return "SearchSqlite"; } -- 2.20.1