aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag
diff options
context:
space:
mode:
authorJeremy Benoist <jeremy.benoist@gmail.com>2016-03-28 14:18:50 +0200
committerJeremy Benoist <jeremy.benoist@gmail.com>2016-03-28 14:18:50 +0200
commit0e49487bb0a004d526eb41e7d3fb44b566441e34 (patch)
treee40e79b4152cc9ae8a625674aabb7d31a765491d /src/Wallabag
parentba2157b270095757eb5af8062df72ce16c497637 (diff)
downloadwallabag-0e49487bb0a004d526eb41e7d3fb44b566441e34.tar.gz
wallabag-0e49487bb0a004d526eb41e7d3fb44b566441e34.tar.zst
wallabag-0e49487bb0a004d526eb41e7d3fb44b566441e34.zip
Remove some complexicity in InstallCommand
Diffstat (limited to 'src/Wallabag')
-rw-r--r--src/Wallabag/CoreBundle/Command/InstallCommand.php14
-rw-r--r--src/Wallabag/CoreBundle/Helper/EntriesExport.php2
2 files changed, 8 insertions, 8 deletions
diff --git a/src/Wallabag/CoreBundle/Command/InstallCommand.php b/src/Wallabag/CoreBundle/Command/InstallCommand.php
index 2d73a9ad..7c3d1c52 100644
--- a/src/Wallabag/CoreBundle/Command/InstallCommand.php
+++ b/src/Wallabag/CoreBundle/Command/InstallCommand.php
@@ -74,10 +74,9 @@ class InstallCommand extends ContainerAwareCommand
74 $fulfilled = true; 74 $fulfilled = true;
75 75
76 $label = '<comment>PDO Drivers</comment>'; 76 $label = '<comment>PDO Drivers</comment>';
77 if (extension_loaded('pdo_sqlite') || extension_loaded('pdo_mysql') || extension_loaded('pdo_pgsql')) { 77 $status = '<info>OK!</info>';
78 $status = '<info>OK!</info>'; 78 $help = '';
79 $help = ''; 79 if (!(extension_loaded('pdo_sqlite') || extension_loaded('pdo_mysql') || extension_loaded('pdo_pgsql'))) {
80 } else {
81 $fulfilled = false; 80 $fulfilled = false;
82 $status = '<error>ERROR!</error>'; 81 $status = '<error>ERROR!</error>';
83 $help = 'Needs one of sqlite, mysql or pgsql PDO drivers'; 82 $help = 'Needs one of sqlite, mysql or pgsql PDO drivers';
@@ -88,11 +87,10 @@ class InstallCommand extends ContainerAwareCommand
88 87
89 foreach ($this->functionExists as $functionRequired) { 88 foreach ($this->functionExists as $functionRequired) {
90 $label = '<comment>'.$functionRequired.'</comment>'; 89 $label = '<comment>'.$functionRequired.'</comment>';
90 $status = '<info>OK!</info>';
91 $help = '';
91 92
92 if (function_exists($functionRequired)) { 93 if (!function_exists($functionRequired)) {
93 $status = '<info>OK!</info>';
94 $help = '';
95 } else {
96 $fulfilled = false; 94 $fulfilled = false;
97 $status = '<error>ERROR!</error>'; 95 $status = '<error>ERROR!</error>';
98 $help = 'You need the '.$functionRequired.' function activated'; 96 $help = 'You need the '.$functionRequired.' function activated';
diff --git a/src/Wallabag/CoreBundle/Helper/EntriesExport.php b/src/Wallabag/CoreBundle/Helper/EntriesExport.php
index 82004a6d..d0680c3f 100644
--- a/src/Wallabag/CoreBundle/Helper/EntriesExport.php
+++ b/src/Wallabag/CoreBundle/Helper/EntriesExport.php
@@ -367,6 +367,8 @@ class EntriesExport
367 /** 367 /**
368 * Return a Serializer object for producing processes that need it (JSON & XML). 368 * Return a Serializer object for producing processes that need it (JSON & XML).
369 * 369 *
370 * @param string $format
371 *
370 * @return Serializer 372 * @return Serializer
371 */ 373 */
372 private function prepareSerializingContent($format) 374 private function prepareSerializingContent($format)