public function __construct( IMaintainableDatabase $db, array $tablesToClone,
$newTablePrefix, $oldTablePrefix = null, $dropCurrentTables = true
) {
+ if ( !$tablesToClone ) {
+ throw new InvalidArgumentException( 'Empty list of tables to clone' );
+ }
$this->db = $db;
$this->tablesToClone = $tablesToClone;
$this->newTablePrefix = $newTablePrefix;
global $wgDBprefix;
$lbFactory = MediaWikiServices::getInstance()->getDBLoadBalancerFactory();
- $lbFactory->setDomainPrefix( $prefix );
+ $lbFactory->setLocalDomainPrefix( $prefix );
$wgDBprefix = $prefix;
}
}