Files
therinaldos.com/wedding-pics/apps/privacy/lib/Migration/Version100Date20190217131943.php
T
david ef1ff240d4
Build & Deploy to DigitalOcean Space / build (push) Failing after 2m38s
migrate therinaldos.com data
2024-05-05 15:50:45 -04:00

50 lines
1.2 KiB
PHP

<?php
declare(strict_types=1);
namespace OCA\Privacy\Migration;
use Closure;
use OCP\DB\ISchemaWrapper;
use OCP\Migration\IOutput;
use OCP\Migration\SimpleMigrationStep;
/**
* Auto-generated migration step: Please modify to your needs!
*/
class Version100Date20190217131943 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();
/*
* Schema generated from database.xml but required changes for
* https://github.com/nextcloud/mail/issues/784 already applied.
*/
if (!$schema->hasTable('privacy_admins')) {
$table = $schema->createTable('privacy_admins');
$table->addColumn('id', 'integer', [
'autoincrement' => true,
'notnull' => true,
'length' => 4,
]);
$table->addColumn('displayname', 'string', [
'notnull' => true,
'length' => 64,
'default' => '',
]);
$table->setPrimaryKey(['id']);
}
return $schema;
}
}