Merge pull request #12312 from nextcloud/bugfix/11527/fix-index-name

Fix index names
This commit is contained in:
Roeland Jago Douma 2018-11-06 21:55:39 +01:00 committed by GitHub
commit 85d2c7ec38
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 6 deletions

View File

@ -70,11 +70,11 @@ class Application extends App {
if (!$table->hasIndex('parent_index')) { if (!$table->hasIndex('parent_index')) {
$subject->addHintForMissingSubject($table->getName(), 'parent_index'); $subject->addHintForMissingSubject($table->getName(), 'parent_index');
} }
if (!$table->hasIndex('uid_owner')) { if (!$table->hasIndex('owner_index')) {
$subject->addHintForMissingSubject($table->getName(), 'uid_owner'); $subject->addHintForMissingSubject($table->getName(), 'owner_index');
} }
if (!$table->hasIndex('uid_initiator')) { if (!$table->hasIndex('initiator_index')) {
$subject->addHintForMissingSubject($table->getName(), 'uid_initiator'); $subject->addHintForMissingSubject($table->getName(), 'initiator_index');
} }
} }

View File

@ -99,7 +99,7 @@ class AddMissingIndices extends Command {
$output->writeln('<info>Share table updated successfully.</info>'); $output->writeln('<info>Share table updated successfully.</info>');
} }
if (!$table->hasIndex('uid_owner')) { if (!$table->hasIndex('owner_index')) {
$output->writeln('<info>Adding additional owner index to the share table, this can take some time...</info>'); $output->writeln('<info>Adding additional owner index to the share table, this can take some time...</info>');
$table->addIndex(['uid_owner'], 'owner_index'); $table->addIndex(['uid_owner'], 'owner_index');
$this->connection->migrateToSchema($schema->getWrappedSchema()); $this->connection->migrateToSchema($schema->getWrappedSchema());
@ -107,7 +107,7 @@ class AddMissingIndices extends Command {
$output->writeln('<info>Share table updated successfully.</info>'); $output->writeln('<info>Share table updated successfully.</info>');
} }
if (!$table->hasIndex('uid_initiator')) { if (!$table->hasIndex('initiator_index')) {
$output->writeln('<info>Adding additional initiator index to the share table, this can take some time...</info>'); $output->writeln('<info>Adding additional initiator index to the share table, this can take some time...</info>');
$table->addIndex(['uid_initiator'], 'initiator_index'); $table->addIndex(['uid_initiator'], 'initiator_index');
$this->connection->migrateToSchema($schema->getWrappedSchema()); $this->connection->migrateToSchema($schema->getWrappedSchema());