Skip to content

Commit

Permalink
Extend propertypath to 4000
Browse files Browse the repository at this point in the history
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
  • Loading branch information
J0WI committed Nov 26, 2019
1 parent 0e87c6f commit aa59c08
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions core/Migrations/Version18000Date20191126000000.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<?php
declare(strict_types=1);

namespace OC\Core\Migrations;

use Closure;
use OCP\DB\ISchemaWrapper;
use OCP\Migration\IOutput;
use OCP\Migration\SimpleMigrationStep;

class Version18000Date20191126000000 extends SimpleMigrationStep {

/**
* @param IOutput $output
* @param Closure $schemaClosure The `\Closure` returns a `ISchemaWrapper`
* @param array $options
* @return null|ISchemaWrapper
*/
public function changeSchema(IOutput $output, Closure $schemaClosure, array $options) {
/** @var ISchemaWrapper $schema */
$schema = $schemaClosure();

if ($schema->hasTable('properties')) {
$table = $schema->getTable('properties');

$table->changeColumn('propertypath', [
'notnull' => true,
'length' => 4000,
'default' => '',
]);
}

return $schema;
}
}

0 comments on commit aa59c08

Please sign in to comment.