35 lines
833 B
PHP
35 lines
833 B
PHP
<?php
|
|
|
|
namespace OCA\GroupfolderFilesystemSnapshots\Migration;
|
|
|
|
use Closure;
|
|
use OCP\DB\ISchemaWrapper;
|
|
use OCP\Migration\SimpleMigrationStep;
|
|
use OCP\Migration\IOutput;
|
|
|
|
class Version131Date20250219152900 extends SimpleMigrationStep {
|
|
|
|
const RESULTS_TABLE = "groupfolder_snapshots_task_results";
|
|
|
|
/**
|
|
* @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();
|
|
|
|
$table = $schema->getTable(self::RESULTS_TABLE);
|
|
|
|
$table->modifyColumn('before_path', [
|
|
'length' => 2000,
|
|
]);
|
|
$table->modifyColumn('current_path', [
|
|
'length' => 2000,
|
|
]);
|
|
|
|
return $schema;
|
|
}
|
|
}
|