diff options
Diffstat (limited to 'app/DoctrineMigrations')
-rw-r--r-- | app/DoctrineMigrations/Version20161024212538.php | 6 | ||||
-rw-r--r-- | app/DoctrineMigrations/Version20161122203647.php | 5 |
2 files changed, 4 insertions, 7 deletions
diff --git a/app/DoctrineMigrations/Version20161024212538.php b/app/DoctrineMigrations/Version20161024212538.php index 7e79cbde..75ff86f1 100644 --- a/app/DoctrineMigrations/Version20161024212538.php +++ b/app/DoctrineMigrations/Version20161024212538.php | |||
@@ -37,9 +37,9 @@ class Version20161024212538 extends AbstractMigration implements ContainerAwareI | |||
37 | 37 | ||
38 | $clientsTable->addForeignKeyConstraint( | 38 | $clientsTable->addForeignKeyConstraint( |
39 | $this->getTable('user'), | 39 | $this->getTable('user'), |
40 | array('user_id'), | 40 | ['user_id'], |
41 | array('id'), | 41 | ['id'], |
42 | array('onDelete' => 'CASCADE') | 42 | ['onDelete' => 'CASCADE'] |
43 | ); | 43 | ); |
44 | } | 44 | } |
45 | 45 | ||
diff --git a/app/DoctrineMigrations/Version20161122203647.php b/app/DoctrineMigrations/Version20161122203647.php index 9c1557eb..94197193 100644 --- a/app/DoctrineMigrations/Version20161122203647.php +++ b/app/DoctrineMigrations/Version20161122203647.php | |||
@@ -42,12 +42,9 @@ class Version20161122203647 extends AbstractMigration implements ContainerAwareI | |||
42 | { | 42 | { |
43 | $userTable = $schema->getTable($this->getTable('user')); | 43 | $userTable = $schema->getTable($this->getTable('user')); |
44 | 44 | ||
45 | $this->skipIf(false === $userTable->hasColumn('expired'), 'It seems that you already played this migration.'); | 45 | $this->skipIf(false === $userTable->hasColumn('expired') || false === $userTable->hasColumn('credentials_expired'), 'It seems that you already played this migration.'); |
46 | 46 | ||
47 | $userTable->dropColumn('expired'); | 47 | $userTable->dropColumn('expired'); |
48 | |||
49 | $this->skipIf(false === $userTable->hasColumn('credentials_expired'), 'It seems that you already played this migration.'); | ||
50 | |||
51 | $userTable->dropColumn('credentials_expired'); | 48 | $userTable->dropColumn('credentials_expired'); |
52 | } | 49 | } |
53 | 50 | ||