- $userTable->addColumn('expired', 'smallint');
- $userTable->addColumn('credentials_expired', 'smallint');
+
+ $this->skipIf(true === $userTable->hasColumn('expired') || true === $userTable->hasColumn('credentials_expired'), 'It seems that you already played this migration.');
+
+ $userTable->addColumn('expired', 'smallint', ['notnull' => false]);
+ $userTable->addColumn('credentials_expired', 'smallint', ['notnull' => false]);
+ }
+
+ private function getTable($tableName)
+ {
+ return $this->container->getParameter('database_table_prefix') . $tableName;