@@ -168,7 +168,7 @@ |
||
168 | 168 | |
169 | 169 | $home = new MenuItem('core.menu.home', $this->factory); |
170 | 170 | $home->setLabel('core.menu.home'); |
171 | - $home->setUri('/' . $locale); |
|
171 | + $home->setUri('/'.$locale); |
|
172 | 172 | $this->items[] = $home; |
173 | 173 | |
174 | 174 | $this->items = array_merge($this->items, array_reverse($items)); |
@@ -17,7 +17,7 @@ |
||
17 | 17 | $io->method('isDecorated') |
18 | 18 | ->willReturn(true); |
19 | 19 | |
20 | - $this->expectOutputString('foo' . "\n"); |
|
20 | + $this->expectOutputString('foo'."\n"); |
|
21 | 21 | ScriptHandler::runCommandOnlyInDevMode('echo "foo"', $io, true); |
22 | 22 | } |
23 | 23 | } |
@@ -1,7 +1,7 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -call_user_func(function () { |
|
4 | - if (! is_file($autoloadFile = __DIR__.'/../vendor/autoload.php')) { |
|
3 | +call_user_func(function() { |
|
4 | + if (!is_file($autoloadFile = __DIR__.'/../vendor/autoload.php')) { |
|
5 | 5 | throw new \LogicException('Could not find vendor/autoload.php. Did you forget to run "composer install --dev"?'); |
6 | 6 | } |
7 | 7 |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | public function getDecoratedMessage($message, $type = null, $isDecorated = true) |
21 | 21 | { |
22 | 22 | if ($isDecorated && $type !== null) { |
23 | - $message = '<' . $type . '>' . $message . '</' . $type . '>'; |
|
23 | + $message = '<'.$type.'>'.$message.'</'.$type.'>'; |
|
24 | 24 | } |
25 | 25 | |
26 | 26 | return $message; |
@@ -34,9 +34,9 @@ discard block |
||
34 | 34 | */ |
35 | 35 | public function ask(IOInterface $io, $question, $default = null) |
36 | 36 | { |
37 | - $question = $this->getDecoratedMessage($question, 'question', $io->isDecorated()) . ' '; |
|
37 | + $question = $this->getDecoratedMessage($question, 'question', $io->isDecorated()).' '; |
|
38 | 38 | if ($default !== null) { |
39 | - $question .= '(' . $this->getDecoratedMessage($default, 'comment', $io->isDecorated()) . ')'; |
|
39 | + $question .= '('.$this->getDecoratedMessage($default, 'comment', $io->isDecorated()).')'; |
|
40 | 40 | } |
41 | 41 | $question .= ': '; |
42 | 42 | |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | */ |
52 | 52 | public function askConfirmation(IOInterface $io, $question, $default = true) |
53 | 53 | { |
54 | - $question = $this->getDecoratedMessage($question, 'question', $io->isDecorated()) . ' '; |
|
54 | + $question = $this->getDecoratedMessage($question, 'question', $io->isDecorated()).' '; |
|
55 | 55 | $question .= '(Y/n): '; |
56 | 56 | |
57 | 57 | return $io->askConfirmation($question, $default); |
@@ -116,8 +116,8 @@ discard block |
||
116 | 116 | protected function replaceSetRubyVar($variableName, $value, $content) |
117 | 117 | { |
118 | 118 | return preg_replace( |
119 | - '/(set.*:' . $variableName . ',.*)\'.*\'/iU', |
|
120 | - '$1\'' . $value . '\'', |
|
119 | + '/(set.*:'.$variableName.',.*)\'.*\'/iU', |
|
120 | + '$1\''.$value.'\'', |
|
121 | 121 | $content |
122 | 122 | ); |
123 | 123 | } |
@@ -19,8 +19,8 @@ discard block |
||
19 | 19 | $io = $event->getIO(); |
20 | 20 | |
21 | 21 | // check if parameters.yml exists |
22 | - $rootDir = realpath(__DIR__ . '/../../../../'); |
|
23 | - if (file_exists($rootDir . '/app/config/parameters.yml')) { |
|
22 | + $rootDir = realpath(__DIR__.'/../../../../'); |
|
23 | + if (file_exists($rootDir.'/app/config/parameters.yml')) { |
|
24 | 24 | $io->write( |
25 | 25 | $installer->getDecoratedMessage( |
26 | 26 | 'Skipping creating the initial config as parameters.yml already exists', |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | $config['client'] = $installer->ask($io, 'client name', $information['client']); |
37 | 37 | $config['project'] = $installer->ask($io, 'project name', $information['project']); |
38 | 38 | |
39 | - $config['database_name'] = substr($config['client'], 0, 8) . '_' . substr($config['project'], 0, 7); |
|
39 | + $config['database_name'] = substr($config['client'], 0, 8).'_'.substr($config['project'], 0, 7); |
|
40 | 40 | $config['database_user'] = $config['database_name']; |
41 | 41 | |
42 | 42 | if ($information['is_local']) { |
@@ -50,11 +50,11 @@ discard block |
||
50 | 50 | |
51 | 51 | // create the database if requested |
52 | 52 | if ($installer->askConfirmation($io, 'Should I create the database?')) { |
53 | - passthru('mysqladmin create ' . $config['database_name']); |
|
53 | + passthru('mysqladmin create '.$config['database_name']); |
|
54 | 54 | } |
55 | 55 | |
56 | 56 | // alter the Capfile if requested |
57 | - $capfilePath = $rootDir . '/Capfile'; |
|
57 | + $capfilePath = $rootDir.'/Capfile'; |
|
58 | 58 | if (file_exists($capfilePath)) { |
59 | 59 | if ($installer->askConfirmation($io, 'Should I alter the Capfile?')) { |
60 | 60 | $installer->updateCapfile($capfilePath, $config); |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | } |
63 | 63 | |
64 | 64 | // alter the dist file if requested |
65 | - $parameterYmlDistPath = $rootDir . '/app/config/parameters.yml.dist'; |
|
65 | + $parameterYmlDistPath = $rootDir.'/app/config/parameters.yml.dist'; |
|
66 | 66 | if (file_exists($parameterYmlDistPath)) { |
67 | 67 | if ($installer->askConfirmation($io, 'Should I alter parameters.yml.dist?')) { |
68 | 68 | $installer->updateYmlFile($parameterYmlDistPath, $config); |
@@ -114,7 +114,7 @@ discard block |
||
114 | 114 | { |
115 | 115 | // make our command look nice |
116 | 116 | if ($io->isDecorated()) { |
117 | - $formattedCommand = '<comment>' . $command . '</comment>'; |
|
117 | + $formattedCommand = '<comment>'.$command.'</comment>'; |
|
118 | 118 | } else { |
119 | 119 | $formattedCommand = $command; |
120 | 120 | } |
@@ -56,10 +56,10 @@ |
||
56 | 56 | $haystack .= $column->dispatch($sqlWalker); |
57 | 57 | } |
58 | 58 | |
59 | - $query = "MATCH(" . $haystack . ") AGAINST (" . $this->needle->dispatch($sqlWalker); |
|
59 | + $query = "MATCH(".$haystack.") AGAINST (".$this->needle->dispatch($sqlWalker); |
|
60 | 60 | |
61 | 61 | if ($this->mode) { |
62 | - $query .= " " . $this->mode->value . " )"; |
|
62 | + $query .= " ".$this->mode->value." )"; |
|
63 | 63 | } else { |
64 | 64 | $query .= " )"; |
65 | 65 | } |
@@ -19,7 +19,7 @@ |
||
19 | 19 | */ |
20 | 20 | public function load(array $configs, ContainerBuilder $container) |
21 | 21 | { |
22 | - $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config')); |
|
22 | + $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config')); |
|
23 | 23 | $loader->load('services.yml'); |
24 | 24 | $loader->load('parameters.yml'); |
25 | 25 | } |
@@ -11,7 +11,7 @@ |
||
11 | 11 | { |
12 | 12 | public function load(array $configs, ContainerBuilder $container) |
13 | 13 | { |
14 | - $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config')); |
|
14 | + $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config')); |
|
15 | 15 | $loader->load('services.yml'); |
16 | 16 | } |
17 | 17 | } |
@@ -15,13 +15,13 @@ |
||
15 | 15 | return [ |
16 | 16 | new Twig_SimpleTest( |
17 | 17 | 'admin', |
18 | - function (BaseUser $user) { |
|
18 | + function(BaseUser $user) { |
|
19 | 19 | return $user instanceof Admin; |
20 | 20 | } |
21 | 21 | ), |
22 | 22 | new Twig_SimpleTest( |
23 | 23 | 'user', |
24 | - function (BaseUser $user) { |
|
24 | + function(BaseUser $user) { |
|
25 | 25 | return $user instanceof User; |
26 | 26 | } |
27 | 27 | ), |