Completed
Pull Request — master (#4)
by Alexis
02:37
created
Tests/app/AppKernel.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,6 +19,6 @@
 block discarded – undo
19 19
 
20 20
     public function registerContainerConfiguration(LoaderInterface $loader)
21 21
     {
22
-        $loader->load(__DIR__.'/../config/config.yml');
22
+        $loader->load(__DIR__ . '/../config/config.yml');
23 23
     }
24 24
 }
Please login to merge, or discard this patch.
Tests/bootstrap.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@
 block discarded – undo
2 2
 
3 3
 $_SERVER['env'] = 'test';
4 4
 use Doctrine\Common\Annotations\AnnotationRegistry;
5
-if (!is_file($loaderFile = __DIR__.'/../vendor/autoload.php')) {
5
+if (!is_file($loaderFile = __DIR__ . '/../vendor/autoload.php')) {
6 6
     throw new \LogicException('Could not find autoload.php in vendor/. Did you run "composer install --dev"?');
7 7
 }
8 8
 $loader = require $loaderFile;
Please login to merge, or discard this patch.
Tests/Builder/MenuBuilderTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -111,7 +111,7 @@
 block discarded – undo
111 111
     {
112 112
         $item = new Item();
113 113
         $item->setMenu($menu);
114
-        $item->setName('Item '.$i);
114
+        $item->setName('Item ' . $i);
115 115
         $item->setPosition($i);
116 116
         $item->setUri('http://alpixel.fr');
117 117
 
Please login to merge, or discard this patch.
DependencyInjection/AlpixelMenuExtension.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
         $configuration = new Configuration();
28 28
         $this->processConfiguration($configuration, $configs);
29 29
 
30
-        $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
30
+        $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config'));
31 31
         $loader->load('services.yml');
32 32
 
33 33
         $menuBuilder = $container->getDefinition('alpixel_menu.builder');
Please login to merge, or discard this patch.
Controller/Admin/CRUD/MenuAdmin.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
     public function createQuery($context = 'list')
13 13
     {
14 14
         $query = parent::createQuery($context);
15
-        $query->addOrderBy($query->getRootAlias().'.locale', 'ASC');
15
+        $query->addOrderBy($query->getRootAlias() . '.locale', 'ASC');
16 16
 
17 17
         return $query;
18 18
     }
@@ -20,7 +20,7 @@  discard block
 block discarded – undo
20 20
     protected function configureRoutes(RouteCollection $collection)
21 21
     {
22 22
         $collection->clearExcept(['list']);
23
-        $collection->add('item', $this->getRouterIdParameter().'/item');
23
+        $collection->add('item', $this->getRouterIdParameter() . '/item');
24 24
     }
25 25
 
26 26
     protected function configureFormFields(FormMapper $formMapper)
Please login to merge, or discard this patch.
Builder/MenuBuilder.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -175,10 +175,10 @@
 block discarded – undo
175 175
 
176 176
         if (($uri = $item->getUri()) !== null) {
177 177
             if ($uri[0] == '/') {
178
-                $baseUri = $this->request->getBasePath().
179
-                           $this->request->getBaseURL().
178
+                $baseUri = $this->request->getBasePath() .
179
+                           $this->request->getBaseURL() .
180 180
                            $uri;
181
-                $uri = $this->request->getSchemeAndHttpHost().$baseUri;
181
+                $uri = $this->request->getSchemeAndHttpHost() . $baseUri;
182 182
 
183 183
                 if ($baseUri === $this->currentUri) {
184 184
                     $menuItem->setCurrent(true);
Please login to merge, or discard this patch.
Validator/Constraints/RouteExistsValidator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -20,8 +20,8 @@
 block discarded – undo
20 20
         $match = false;
21 21
         if (strpos($value, '/') === 0) {
22 22
             $context = $this->router->getContext();
23
-            $baseUrl = $context->getScheme().'://'.$context->getHost().$context->getBaseUrl();
24
-            $value = $baseUrl.$value;
23
+            $baseUrl = $context->getScheme() . '://' . $context->getHost() . $context->getBaseUrl();
24
+            $value = $baseUrl . $value;
25 25
         }
26 26
 
27 27
         $handle = curl_init($value);
Please login to merge, or discard this patch.
Controller/Admin/CRUD/ItemAdmin.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
 
26 26
     protected function configureRoutes(RouteCollection $collection)
27 27
     {
28
-        $collection->add('move', $this->getRouterIdParameter().'/move/{position}');
28
+        $collection->add('move', $this->getRouterIdParameter() . '/move/{position}');
29 29
     }
30 30
 
31 31
     public function getPersistentParameters()
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
     {
44 44
         $id = $this->getRequest()->query->getInt('menu');
45 45
         $query = parent::createQuery($context);
46
-        $query->join($query->getRootAlias().'.menu', 'm')
46
+        $query->join($query->getRootAlias() . '.menu', 'm')
47 47
             ->where('m.id = :id')
48 48
             ->setParameters([
49 49
                 'id' => $id,
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
                     'label'         => 'Menu',
64 64
                     'required'      => true,
65 65
                     'property'      => 'name',
66
-                    'query_builder' => function (EntityRepository $entityRepository) use ($id) {
66
+                    'query_builder' => function(EntityRepository $entityRepository) use ($id) {
67 67
                         $query = $entityRepository->createQuerybuilder('m');
68 68
                         if ($id == null) {
69 69
                             return $query;
Please login to merge, or discard this patch.