Completed
Pull Request — master (#3788)
by Craig
01:31
created
src/lib/legacy/Zikula/ClassProperties.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@
 block discarded – undo
54 54
         }
55 55
 
56 56
         foreach ($properties as $k => $v) {
57
-            $lookup = 'set'.strtolower($k);
57
+            $lookup = 'set' . strtolower($k);
58 58
             if (isset($methodMap[$lookup])) {
59 59
                 $reflectionMethod = new ReflectionMethod($className, $methodMap[$lookup]);
60 60
                 $reflectionMethod->invoke($object, $v);
Please login to merge, or discard this patch.
src/lib/Zikula/Core/AbstractBundle.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
     public function getInstallerClass()
55 55
     {
56 56
         $ns = $this->getNamespace();
57
-        $class = $ns.'\\'.substr($ns, strrpos($ns, '\\') + 1, strlen($ns)).'Installer';
57
+        $class = $ns . '\\' . substr($ns, strrpos($ns, '\\') + 1, strlen($ns)) . 'Installer';
58 58
 
59 59
         return $class;
60 60
     }
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
     public function getVersionClass()
67 67
     {
68 68
         $ns = $this->getNamespace();
69
-        $class = $ns.'\\'.substr($ns, strrpos($ns, '\\') + 1, strlen($ns)).'Version';
69
+        $class = $ns . '\\' . substr($ns, strrpos($ns, '\\') + 1, strlen($ns)) . 'Version';
70 70
 
71 71
         return $class;
72 72
     }
@@ -88,7 +88,7 @@  discard block
 block discarded – undo
88 88
      */
89 89
     public function getLocalePath()
90 90
     {
91
-        return $this->getPath().'/Resources/locale';
91
+        return $this->getPath() . '/Resources/locale';
92 92
     }
93 93
 
94 94
     /**
@@ -98,7 +98,7 @@  discard block
 block discarded – undo
98 98
      */
99 99
     public function getViewsPath()
100 100
     {
101
-        return $this->getPath().'/Resources/views';
101
+        return $this->getPath() . '/Resources/views';
102 102
     }
103 103
 
104 104
     /**
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
      */
109 109
     public function getConfigPath()
110 110
     {
111
-        return $this->getPath().'/Resources/config';
111
+        return $this->getPath() . '/Resources/config';
112 112
     }
113 113
 
114 114
     /**
@@ -156,9 +156,9 @@  discard block
 block discarded – undo
156 156
         $type = $this->getNameType();
157 157
         $typeLower = strtolower($type);
158 158
         if (null === $this->extension) {
159
-            $basename = preg_replace('/'.$type.'/', '', $this->getName());
159
+            $basename = preg_replace('/' . $type . '/', '', $this->getName());
160 160
 
161
-            $class = $this->getNamespace().'\\DependencyInjection\\'.$basename.'Extension';
161
+            $class = $this->getNamespace() . '\\DependencyInjection\\' . $basename . 'Extension';
162 162
             if (class_exists($class)) {
163 163
                 $extension = new $class();
164 164
 
Please login to merge, or discard this patch.
src/lib/Zikula/Core/RouteUrl.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@
 block discarded – undo
47 47
     {
48 48
         $router = \ServiceUtil::get('router');
49 49
         $fqUrl = (is_bool($fqUrl) && $fqUrl) ? RouterInterface::ABSOLUTE_URL : RouterInterface::ABSOLUTE_PATH;
50
-        $fragment =  (!empty($this->fragment)) ? '#' . $this->fragment : '';
50
+        $fragment = (!empty($this->fragment)) ? '#' . $this->fragment : '';
51 51
 
52 52
         $oldScheme = $router->getContext()->getScheme();
53 53
         if ($ssl) {
Please login to merge, or discard this patch.
FormExtensionBundle/DependencyInjection/ZikulaFormExtensionExtension.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
      */
30 30
     public function load(array $configs, ContainerBuilder $container)
31 31
     {
32
-        $loader = new YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
32
+        $loader = new YamlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config'));
33 33
         $loader->load('services.yml');
34 34
     }
35 35
 }
Please login to merge, or discard this patch.
CoreInstallerBundle/Validator/Constraints/ValidPdoConnectionValidator.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -43,8 +43,7 @@
 block discarded – undo
43 43
             $dbh = new \PDO("$object[database_driver]:host=$object[database_host];dbname=$object[database_name]", $object['database_user'], $object['database_password']);
44 44
             $dbh->setAttribute(\PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION);
45 45
             $sql = ($object['database_driver'] == 'mysql' || $object['database_driver'] == 'mysqli') ?
46
-                "SHOW TABLES FROM `$object[database_name]` LIKE '%'" :
47
-                "SHOW TABLES FROM $object[database_name] LIKE '%'";
46
+                "SHOW TABLES FROM `$object[database_name]` LIKE '%'" : "SHOW TABLES FROM $object[database_name] LIKE '%'";
48 47
             $tables = $dbh->query($sql);
49 48
             if (!is_object($tables)) {
50 49
                 $this->context->buildViolation($this->__('Error! Determination existing tables failed.') . ' SQL: ' . $sql)
Please login to merge, or discard this patch.
lib/Zikula/Bundle/CoreInstallerBundle/Controller/AjaxInstallController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@
 block discarded – undo
43 43
     public function __construct(ContainerInterface $container)
44 44
     {
45 45
         parent::__construct($container);
46
-        $this->yamlManager = new YamlDumper($this->container->get('kernel')->getRootDir() .'/config', 'custom_parameters.yml');
46
+        $this->yamlManager = new YamlDumper($this->container->get('kernel')->getRootDir() . '/config', 'custom_parameters.yml');
47 47
     }
48 48
 
49 49
     public function ajaxAction(Request $request)
Please login to merge, or discard this patch.
src/lib/Zikula/Bundle/CoreInstallerBundle/Stage/Upgrade/LoginStage.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@
 block discarded – undo
26 26
     public function __construct(ContainerInterface $container)
27 27
     {
28 28
         $this->container = $container;
29
-        $this->yamlManager = new YamlDumper($this->container->get('kernel')->getRootDir() .'/config', 'custom_parameters.yml');
29
+        $this->yamlManager = new YamlDumper($this->container->get('kernel')->getRootDir() . '/config', 'custom_parameters.yml');
30 30
     }
31 31
 
32 32
     public function getName()
Please login to merge, or discard this patch.
src/lib/Zikula/Bundle/CoreInstallerBundle/Util/ZikulaRequirements.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
     public function runSymfonyChecks($parameters = [])
25 25
     {
26 26
         try {
27
-            $path = realpath(__DIR__.'/../../../../../app/SymfonyRequirements.php');
27
+            $path = realpath(__DIR__ . '/../../../../../app/SymfonyRequirements.php');
28 28
             require $path;
29 29
             $symfonyRequirements = new \SymfonyRequirements();
30 30
             $this->addZikulaPathRequirements($symfonyRequirements, $parameters);
@@ -44,8 +44,8 @@  discard block
 block discarded – undo
44 44
         if ($requirement->isFulfilled()) {
45 45
             return;
46 46
         }
47
-        $errorMessage = wordwrap($requirement->getTestMessage(), $lineSize - 3, PHP_EOL.'   ').PHP_EOL;
48
-        $errorMessage .= '   > '.wordwrap($requirement->getHelpText(), $lineSize - 5, PHP_EOL.'   > ').PHP_EOL;
47
+        $errorMessage = wordwrap($requirement->getTestMessage(), $lineSize - 3, PHP_EOL . '   ') . PHP_EOL;
48
+        $errorMessage .= '   > ' . wordwrap($requirement->getHelpText(), $lineSize - 5, PHP_EOL . '   > ') . PHP_EOL;
49 49
 
50 50
         return $errorMessage;
51 51
     }
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
         $symfonyRequirements->addRequirement(
67 67
             is_writable($src . '/' . $parameters['datadir']),
68 68
             $parameters['datadir'] . '/ directory must be writable',
69
-            'Change the permissions of "<strong>' . $parameters['datadir']. '</strong>" directory so that the web server can write into it.'
69
+            'Change the permissions of "<strong>' . $parameters['datadir'] . '</strong>" directory so that the web server can write into it.'
70 70
         );
71 71
         // @todo @deprecated
72 72
         $symfonyRequirements->addRequirement(
Please login to merge, or discard this patch.
src/lib/Zikula/Bundle/CoreInstallerBundle/Command/Install/StartCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -117,7 +117,7 @@
 block discarded – undo
117 117
         }
118 118
 
119 119
         // write the parameters to personal_config.php and custom_parameters.yml
120
-        $yamlManager = new YamlDumper($this->getContainer()->get('kernel')->getRootDir() .'/config', 'custom_parameters.yml', 'parameters.yml');
120
+        $yamlManager = new YamlDumper($this->getContainer()->get('kernel')->getRootDir() . '/config', 'custom_parameters.yml', 'parameters.yml');
121 121
         $params = array_merge($yamlManager->getParameters(), $settings);
122 122
         $dbh = new \PDO("$params[database_driver]:host=$params[database_host];dbname=$params[database_name]", $params['database_user'], $params['database_password']);
123 123
         $params['database_server_version'] = $dbh->getAttribute(\PDO::ATTR_SERVER_VERSION);
Please login to merge, or discard this patch.