]> git.immae.eu Git - github/wallabag/wallabag.git/blame - app/DoctrineMigrations/Version20160812120952.php
Added name on client
[github/wallabag/wallabag.git] / app / DoctrineMigrations / Version20160812120952.php
CommitLineData
9c545fe0
TC
1<?php
2
3namespace Application\Migrations;
4
5use Doctrine\DBAL\Migrations\AbstractMigration;
6use Doctrine\DBAL\Schema\Schema;
7
8class Version20160812120952 extends AbstractMigration
9{
10 /**
11 * @param Schema $schema
12 */
13 public function up(Schema $schema)
14 {
15 $this->addSql('ALTER TABLE wallabag_oauth2_clients ADD name CLOB DEFAULT NULL COLLATE BINARY');
16 }
17
18 /**
19 * @param Schema $schema
20 */
21 public function down(Schema $schema)
22 {
23 $this->abortIf($this->connection->getDatabasePlatform()->getName() == 'sqlite', 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
24 $this->addSql('ALTER TABLE wallabag_oauth2_clients DROP COLUMN name;
25');
26 }
27}