mirror of
https://github.com/nextcloud/server.git
synced 2026-06-11 09:42:09 -04:00
fix(db)!: Doctrine\DBAL\Connection::getSchemaManager was removed, use Connection::createSchemaManager instead
Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
parent
466f455e93
commit
287d5271e0
5 changed files with 7 additions and 7 deletions
|
|
@ -245,7 +245,7 @@ class ConvertType extends Command implements CompletionAwareInterface {
|
|||
$output->writeln('<info>Clearing schema in new database</info>');
|
||||
}
|
||||
foreach ($toTables as $table) {
|
||||
$db->getSchemaManager()->dropTable($table);
|
||||
$db->createSchemaManager()->dropTable($table);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -258,7 +258,7 @@ class ConvertType extends Command implements CompletionAwareInterface {
|
|||
}
|
||||
return preg_match($filterExpression, $asset) !== false;
|
||||
});
|
||||
return $db->getSchemaManager()->listTableNames();
|
||||
return $db->createSchemaManager()->listTableNames();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -548,7 +548,7 @@ class Connection extends PrimaryReadReplicaConnection {
|
|||
*/
|
||||
public function dropTable($table) {
|
||||
$table = $this->tablePrefix . trim($table);
|
||||
$schema = $this->getSchemaManager();
|
||||
$schema = $this->createSchemaManager();
|
||||
if ($schema->tablesExist([$table])) {
|
||||
$schema->dropTable($table);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ class OracleConnection extends Connection {
|
|||
public function dropTable($table) {
|
||||
$table = $this->tablePrefix . trim($table);
|
||||
$table = $this->quoteIdentifier($table);
|
||||
$schema = $this->getSchemaManager();
|
||||
$schema = $this->createSchemaManager();
|
||||
if ($schema->tablesExist([$table])) {
|
||||
$schema->dropTable($table);
|
||||
}
|
||||
|
|
@ -83,7 +83,7 @@ class OracleConnection extends Connection {
|
|||
public function tableExists($table) {
|
||||
$table = $this->tablePrefix . trim($table);
|
||||
$table = $this->quoteIdentifier($table);
|
||||
$schema = $this->getSchemaManager();
|
||||
$schema = $this->createSchemaManager();
|
||||
return $schema->tablesExist([$table]);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ class PgSqlTools {
|
|||
return preg_match($filterExpression, $asset) !== false;
|
||||
});
|
||||
|
||||
foreach ($conn->getSchemaManager()->listSequences() as $sequence) {
|
||||
foreach ($conn->createSchemaManager()->listSequences() as $sequence) {
|
||||
$sequenceName = $sequence->getName();
|
||||
$sqlInfo = 'SELECT table_schema, table_name, column_name
|
||||
FROM information_schema.columns
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ class RepairCollationTest extends TestCase {
|
|||
}
|
||||
|
||||
protected function tearDown(): void {
|
||||
$this->connection->getInner()->getSchemaManager()->dropTable($this->tableName);
|
||||
$this->connection->getInner()->createSchemaManager()->dropTable($this->tableName);
|
||||
parent::tearDown();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue