X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=app%2FDoctrineMigrations%2FVersion20160401000000.php;fp=app%2FDoctrineMigrations%2FVersion20160401000000.php;h=9916321fb799298a5de42b4a9545c85da2ea7edc;hb=ad46f2fb46bf97d520a82ec5c15266e3c48c4e0b;hp=54bfb0f033390db0ccd47874009094c7f1372095;hpb=43e1711eb66a55e954bcffa2f37fd30c1b3b1fae;p=github%2Fwallabag%2Fwallabag.git diff --git a/app/DoctrineMigrations/Version20160401000000.php b/app/DoctrineMigrations/Version20160401000000.php index 54bfb0f0..9916321f 100644 --- a/app/DoctrineMigrations/Version20160401000000.php +++ b/app/DoctrineMigrations/Version20160401000000.php @@ -28,13 +28,7 @@ class Version20160401000000 extends AbstractMigration implements ContainerAwareI */ public function up(Schema $schema) { - try { - $schema->getTable($this->getTable('entry')); - - $this->skipIf(true, 'Database already initialized'); - } catch (SchemaException $e) { - // it's ok, the table does not exist we can proceed to the initial migration - } + $this->skipIf($schema->hasTable($this->getTable('entry')), 'Database already initialized'); switch ($this->connection->getDatabasePlatform()->getName()) { case 'sqlite':