summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorDaniel Kesselberg <mail@danielkesselberg.de>2020-06-30 22:12:06 +0200
committerDaniel Kesselberg <mail@danielkesselberg.de>2020-06-30 23:46:22 +0200
commit87dd760a89891d15f75175e5caa43a3983a28d38 (patch)
treeb9365127a8f6856044739f32329d88e14684ee8a /lib
parent43216f0ac9e3841747019b8c2def0c58e71b8cca (diff)
downloadnextcloud-server-87dd760a89891d15f75175e5caa43a3983a28d38.tar.gz
nextcloud-server-87dd760a89891d15f75175e5caa43a3983a28d38.zip
Replace TYPE with TYPES
As TYPE::* is deprecated. Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/DB/MigrationService.php6
-rw-r--r--lib/public/Migration/BigIntMigration.php5
2 files changed, 6 insertions, 5 deletions
diff --git a/lib/private/DB/MigrationService.php b/lib/private/DB/MigrationService.php
index 6685c1917f5..62f1d731f55 100644
--- a/lib/private/DB/MigrationService.php
+++ b/lib/private/DB/MigrationService.php
@@ -34,7 +34,7 @@ use Doctrine\DBAL\Schema\Schema;
use Doctrine\DBAL\Schema\SchemaException;
use Doctrine\DBAL\Schema\Sequence;
use Doctrine\DBAL\Schema\Table;
-use Doctrine\DBAL\Types\Type;
+use Doctrine\DBAL\Types\Types;
use OC\App\InfoParser;
use OC\IntegrityCheck\Helpers\AppLocator;
use OC\Migration\SimpleOutput;
@@ -165,8 +165,8 @@ class MigrationService {
}
$table = $schema->createTable('migrations');
- $table->addColumn('app', Type::STRING, ['length' => 255]);
- $table->addColumn('version', Type::STRING, ['length' => 255]);
+ $table->addColumn('app', Types::STRING, ['length' => 255]);
+ $table->addColumn('version', Types::STRING, ['length' => 255]);
$table->setPrimaryKey(['app', 'version']);
$this->connection->migrateToSchema($schema->getWrappedSchema());
diff --git a/lib/public/Migration/BigIntMigration.php b/lib/public/Migration/BigIntMigration.php
index 251b7a908d7..cf08acd8387 100644
--- a/lib/public/Migration/BigIntMigration.php
+++ b/lib/public/Migration/BigIntMigration.php
@@ -24,6 +24,7 @@
namespace OCP\Migration;
use Doctrine\DBAL\Types\Type;
+use Doctrine\DBAL\Types\Types;
use OCP\DB\ISchemaWrapper;
/**
@@ -56,8 +57,8 @@ abstract class BigIntMigration extends SimpleMigrationStep {
foreach ($columns as $columnName) {
$column = $table->getColumn($columnName);
- if ($column->getType()->getName() !== Type::BIGINT) {
- $column->setType(Type::getType(Type::BIGINT));
+ if ($column->getType()->getName() !== Types::BIGINT) {
+ $column->setType(Type::getType(Types::BIGINT));
$column->setOptions(['length' => 20]);
}
}