Merge pull request #15312 from nextcloud/backport/15289/stable16

[stable16] Remove the custom prefix from the table name length when checking on …
This commit is contained in:
Roeland Jago Douma 2019-04-30 19:45:27 +02:00 committed by GitHub
commit 755543879b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -547,7 +547,7 @@ class MigrationService {
if (!$isUsingDefaultName && \strlen($indexName) > 30) {
throw new \InvalidArgumentException('Primary index name on "' . $table->getName() . '" is too long.');
}
if ($isUsingDefaultName && \strlen($table->getName()) > 26) {
if ($isUsingDefaultName && \strlen($table->getName()) - $prefixLength > 23) {
throw new \InvalidArgumentException('Primary index name on "' . $table->getName() . '" is too long.');
}
}