diff options
Diffstat (limited to 'src/Wallabag/CoreBundle/Command')
-rw-r--r-- | src/Wallabag/CoreBundle/Command/InstallCommand.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/Wallabag/CoreBundle/Command/InstallCommand.php b/src/Wallabag/CoreBundle/Command/InstallCommand.php index 29d91109..1bd76ae3 100644 --- a/src/Wallabag/CoreBundle/Command/InstallCommand.php +++ b/src/Wallabag/CoreBundle/Command/InstallCommand.php | |||
@@ -273,10 +273,11 @@ class InstallCommand extends ContainerAwareCommand | |||
273 | */ | 273 | */ |
274 | private function isDatabasePresent() | 274 | private function isDatabasePresent() |
275 | { | 275 | { |
276 | $databaseName = $this->getContainer()->getParameter('database_name'); | 276 | $connection = $this->getContainer()->get('doctrine')->getManager()->getConnection(); |
277 | $databaseName = $connection->getDatabase(); | ||
277 | 278 | ||
278 | try { | 279 | try { |
279 | $schemaManager = $this->getContainer()->get('doctrine')->getManager()->getConnection()->getSchemaManager(); | 280 | $schemaManager = $connection->getSchemaManager(); |
280 | } catch (\Exception $exception) { | 281 | } catch (\Exception $exception) { |
281 | if (false !== strpos($exception->getMessage(), sprintf("Unknown database '%s'", $databaseName))) { | 282 | if (false !== strpos($exception->getMessage(), sprintf("Unknown database '%s'", $databaseName))) { |
282 | return false; | 283 | return false; |