@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | $commands = []; |
56 | 56 | |
57 | 57 | /** @var \DirectoryIterator $fileInfo */ |
58 | - foreach (new \DirectoryIterator(__DIR__ . '/Commands') as $fileInfo) |
|
58 | + foreach (new \DirectoryIterator(__DIR__.'/Commands') as $fileInfo) |
|
59 | 59 | { |
60 | 60 | if ($fileInfo->isDot()) |
61 | 61 | { |
@@ -75,7 +75,7 @@ discard block |
||
75 | 75 | } |
76 | 76 | |
77 | 77 | $command = $subFileInfo->getBasename('.php'); |
78 | - $className = __NAMESPACE__ . "\\Commands\\$namespace\\$command"; |
|
78 | + $className = __NAMESPACE__."\\Commands\\$namespace\\$command"; |
|
79 | 79 | |
80 | 80 | if (!class_exists($className)) |
81 | 81 | { |
@@ -85,14 +85,14 @@ discard block |
||
85 | 85 | // If the class isn't instantiable, it isn't a valid command |
86 | 86 | if ((new \ReflectionClass($className))->isInstantiable()) |
87 | 87 | { |
88 | - $commands[strtolower("$namespace:" . str_replace('Command', '', $command))] = $this->getContainer()->get($className); |
|
88 | + $commands[strtolower("$namespace:".str_replace('Command', '', $command))] = $this->getContainer()->get($className); |
|
89 | 89 | } |
90 | 90 | } |
91 | 91 | } |
92 | 92 | else |
93 | 93 | { |
94 | 94 | $command = $fileInfo->getBasename('.php'); |
95 | - $className = __NAMESPACE__ . "\\Commands\\$command"; |
|
95 | + $className = __NAMESPACE__."\\Commands\\$command"; |
|
96 | 96 | |
97 | 97 | if (!class_exists($className)) |
98 | 98 | { |
@@ -87,15 +87,15 @@ |
||
87 | 87 | |
88 | 88 | // Allow the next patch release after this one |
89 | 89 | $nextPatch = $explodedVersion[2] + 1; |
90 | - $versions[] = $explodedVersion[0] . '.' . $explodedVersion[1] . '.' . $nextPatch; |
|
90 | + $versions[] = $explodedVersion[0].'.'.$explodedVersion[1].'.'.$nextPatch; |
|
91 | 91 | |
92 | 92 | // And allow the next minor release after this one |
93 | 93 | $nextMinor = $explodedVersion[1] + 1; |
94 | - $versions[] = $explodedVersion[0] . '.' . $nextMinor . '.0'; |
|
94 | + $versions[] = $explodedVersion[0].'.'.$nextMinor.'.0'; |
|
95 | 95 | } |
96 | 96 | |
97 | 97 | // Store the version data now |
98 | - $path = APPROOT . '/versions/joomla.json'; |
|
98 | + $path = APPROOT.'/versions/joomla.json'; |
|
99 | 99 | |
100 | 100 | if (file_put_contents($path, json_encode($versions)) === false) |
101 | 101 | { |
@@ -155,7 +155,7 @@ discard block |
||
155 | 155 | } |
156 | 156 | |
157 | 157 | // Import the valid release listing |
158 | - $path = APPROOT . '/versions/joomla.json'; |
|
158 | + $path = APPROOT.'/versions/joomla.json'; |
|
159 | 159 | |
160 | 160 | if (!file_exists($path)) |
161 | 161 | { |
@@ -220,7 +220,7 @@ discard block |
||
220 | 220 | } |
221 | 221 | |
222 | 222 | // Import the valid release listing |
223 | - $path = APPROOT . '/versions/php.json'; |
|
223 | + $path = APPROOT.'/versions/php.json'; |
|
224 | 224 | |
225 | 225 | if (!file_exists($path)) |
226 | 226 | { |
@@ -68,7 +68,7 @@ |
||
68 | 68 | { |
69 | 69 | return new Migrations( |
70 | 70 | $container->get('db'), |
71 | - new Filesystem(new Local(APPROOT . '/etc')) |
|
71 | + new Filesystem(new Local(APPROOT.'/etc')) |
|
72 | 72 | ); |
73 | 73 | } |
74 | 74 | } |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | |
94 | 94 | $level = strtoupper($config->get('log.application', $config->get('log.level', 'error'))); |
95 | 95 | |
96 | - return new StreamHandler(APPROOT . '/logs/stats.log', constant('\\Monolog\\Logger::' . $level)); |
|
96 | + return new StreamHandler(APPROOT.'/logs/stats.log', constant('\\Monolog\\Logger::'.$level)); |
|
97 | 97 | } |
98 | 98 | |
99 | 99 | /** |
@@ -113,7 +113,7 @@ discard block |
||
113 | 113 | // If database debugging is enabled then force the logger's error level to DEBUG, otherwise use the level defined in the app config |
114 | 114 | $level = $config->get('database.debug', false) ? 'DEBUG' : strtoupper($config->get('log.database', $config->get('log.level', 'error'))); |
115 | 115 | |
116 | - return new StreamHandler(APPROOT . '/logs/stats.log', constant('\\Monolog\\Logger::' . $level)); |
|
116 | + return new StreamHandler(APPROOT.'/logs/stats.log', constant('\\Monolog\\Logger::'.$level)); |
|
117 | 117 | } |
118 | 118 | |
119 | 119 | /** |
@@ -89,11 +89,11 @@ |
||
89 | 89 | public function outputTitle(string $title, string $subTitle = '', int $width = 60) : CliApplication |
90 | 90 | { |
91 | 91 | $this->out(str_repeat('-', $width)); |
92 | - $this->out(str_repeat(' ', $width / 2 - (strlen($title) / 2)) . '<title>' . $title . '</title>'); |
|
92 | + $this->out(str_repeat(' ', $width / 2 - (strlen($title) / 2)).'<title>'.$title.'</title>'); |
|
93 | 93 | |
94 | 94 | if ($subTitle) |
95 | 95 | { |
96 | - $this->out(str_repeat(' ', $width / 2 - (strlen($subTitle) / 2)) . '<b>' . $subTitle . '</b>'); |
|
96 | + $this->out(str_repeat(' ', $width / 2 - (strlen($subTitle) / 2)).'<b>'.$subTitle.'</b>'); |
|
97 | 97 | } |
98 | 98 | |
99 | 99 | $this->out(str_repeat('-', $width)); |
@@ -161,7 +161,7 @@ |
||
161 | 161 | */ |
162 | 162 | private function doMigration(string $version) |
163 | 163 | { |
164 | - $sqlFile = 'migrations/' . $version . '.sql'; |
|
164 | + $sqlFile = 'migrations/'.$version.'.sql'; |
|
165 | 165 | |
166 | 166 | if (!$this->filesystem->has($sqlFile)) |
167 | 167 | { |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | ->out('1) Yes') |
78 | 78 | ->out('2) No') |
79 | 79 | ->out() |
80 | - ->out('<question>' . g11n3t('Select:') . '</question>', false); |
|
80 | + ->out('<question>'.g11n3t('Select:').'</question>', false); |
|
81 | 81 | |
82 | 82 | $in = trim($this->getApplication()->in()); |
83 | 83 | |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | $this->getApplication()->out('No database found.') |
100 | 100 | ->out('Creating the database...', false); |
101 | 101 | |
102 | - $this->db->setQuery('CREATE DATABASE ' . $this->db->quoteName($this->getApplication()->get('database.name'))) |
|
102 | + $this->db->setQuery('CREATE DATABASE '.$this->db->quoteName($this->getApplication()->get('database.name'))) |
|
103 | 103 | ->execute(); |
104 | 104 | |
105 | 105 | $this->db->select($this->getApplication()->get('database.name')); |
@@ -162,7 +162,7 @@ discard block |
||
162 | 162 | */ |
163 | 163 | private function processSql() : InstallCommand |
164 | 164 | { |
165 | - $fName = APPROOT . '/etc/mysql.sql'; |
|
165 | + $fName = APPROOT.'/etc/mysql.sql'; |
|
166 | 166 | |
167 | 167 | if (!file_exists($fName)) |
168 | 168 | { |
@@ -101,17 +101,17 @@ |
||
101 | 101 | $explodedVersion = explode('.', $version); |
102 | 102 | |
103 | 103 | $nextPatch = $explodedVersion[2] + 1; |
104 | - $versions[] = $explodedVersion[0] . '.' . $explodedVersion[1] . '.' . $nextPatch; |
|
104 | + $versions[] = $explodedVersion[0].'.'.$explodedVersion[1].'.'.$nextPatch; |
|
105 | 105 | } |
106 | 106 | |
107 | 107 | // Use $branch from the previous loop to allow the next minor version (PHP's master branch) |
108 | 108 | $explodedVersion = explode('.', $branch); |
109 | 109 | |
110 | 110 | $nextMinor = $explodedVersion[1] + 1; |
111 | - $versions[] = $explodedVersion[0] . '.' . $nextMinor . '.0'; |
|
111 | + $versions[] = $explodedVersion[0].'.'.$nextMinor.'.0'; |
|
112 | 112 | |
113 | 113 | // Store the version data now |
114 | - $path = APPROOT . '/versions/php.json'; |
|
114 | + $path = APPROOT.'/versions/php.json'; |
|
115 | 115 | |
116 | 116 | if (file_put_contents($path, json_encode($versions)) === false) |
117 | 117 | { |