@@ -47,7 +47,7 @@ discard block  | 
                                                    ||
| 47 | 47 | 'vertical',  | 
                                                        
| 48 | 48 | null,  | 
                                                        
| 49 | 49 | ])  | 
                                                        
| 50 | -            ->setNormalizer('position', function (Options $options, $value) { | 
                                                        |
| 50 | +            ->setNormalizer('position', function(Options $options, $value) { | 
                                                        |
| 51 | 51 |                  if ('top' === $this->menuName && null === $value) { | 
                                                        
| 52 | 52 | $value = 'horizontal';  | 
                                                        
| 53 | 53 | }  | 
                                                        
@@ -58,7 +58,7 @@ discard block  | 
                                                    ||
| 58 | 58 | |
| 59 | 59 | return $value;  | 
                                                        
| 60 | 60 | })  | 
                                                        
| 61 | -            ->setNormalizer('template', function (Options $options, $value) { | 
                                                        |
| 61 | +            ->setNormalizer('template', function(Options $options, $value) { | 
                                                        |
| 62 | 62 | // If a template is defined, use it  | 
                                                        
| 63 | 63 |                  if ($value) { | 
                                                        
| 64 | 64 | return $value;  | 
                                                        
@@ -76,7 +76,7 @@ discard block  | 
                                                    ||
| 76 | 76 | |
| 77 | 77 | return $value;  | 
                                                        
| 78 | 78 | })  | 
                                                        
| 79 | -            ->setNormalizer('attr', function (Options $options, $value) { | 
                                                        |
| 79 | +            ->setNormalizer('attr', function(Options $options, $value) { | 
                                                        |
| 80 | 80 |                  $position = $options->offsetGet('position'); | 
                                                        
| 81 | 81 | |
| 82 | 82 |                  if (!key_exists('class', $value)) { | 
                                                        
@@ -99,7 +99,7 @@ discard block  | 
                                                    ||
| 99 | 99 | |
| 100 | 100 | return $value;  | 
                                                        
| 101 | 101 | })  | 
                                                        
| 102 | -            ->setNormalizer('item_css_class', function (Options $options, $value) { | 
                                                        |
| 102 | +            ->setNormalizer('item_css_class', function(Options $options, $value) { | 
                                                        |
| 103 | 103 |                  $position = $options->offsetGet('position'); | 
                                                        
| 104 | 104 | |
| 105 | 105 |                  if (!$value) { | 
                                                        
@@ -116,7 +116,7 @@ discard block  | 
                                                    ||
| 116 | 116 | |
| 117 | 117 | return trim($value);  | 
                                                        
| 118 | 118 | })  | 
                                                        
| 119 | -            ->setNormalizer('brand', function (Options $options, $value) { | 
                                                        |
| 119 | +            ->setNormalizer('brand', function(Options $options, $value) { | 
                                                        |
| 120 | 120 |                  if (null === $value && 'horizontal' === $options->offsetGet('position')) { | 
                                                        
| 121 | 121 | $value = $this->applicationName;  | 
                                                        
| 122 | 122 | }  | 
                                                        
@@ -137,7 +137,7 @@ discard block  | 
                                                    ||
| 137 | 137 | */  | 
                                                        
| 138 | 138 | protected function getFieldsNormalizer()  | 
                                                        
| 139 | 139 |      { | 
                                                        
| 140 | -        return function (Options $options, $fields) { | 
                                                        |
| 140 | +        return function(Options $options, $fields) { | 
                                                        |
| 141 | 141 | $normalizedFields = [];  | 
                                                        
| 142 | 142 | |
| 143 | 143 |              foreach ($fields as $name => $field) { | 
                                                        
@@ -159,7 +159,7 @@ discard block  | 
                                                    ||
| 159 | 159 | */  | 
                                                        
| 160 | 160 | protected function getOrderNormalizer()  | 
                                                        
| 161 | 161 |      { | 
                                                        
| 162 | -        return function (Options $options, $order) { | 
                                                        |
| 162 | +        return function(Options $options, $order) { | 
                                                        |
| 163 | 163 |              foreach ($order as $field => $sort) { | 
                                                        
| 164 | 164 |                  if (!is_string($sort) || !is_string($field) || !in_array(strtolower($sort), ['asc', 'desc'])) { | 
                                                        
| 165 | 165 |                      throw new Exception('Order value should be an array of string (["field" => $key]), got '.gettype($sort)); | 
                                                        
@@ -178,7 +178,7 @@ discard block  | 
                                                    ||
| 178 | 178 | */  | 
                                                        
| 179 | 179 | protected function getLoadStrategyNormalizer()  | 
                                                        
| 180 | 180 |      { | 
                                                        
| 181 | -        return function (Options $options, $value) { | 
                                                        |
| 181 | +        return function(Options $options, $value) { | 
                                                        |
| 182 | 182 |              if (!$value) { | 
                                                        
| 183 | 183 |                  if ('create' == $this->actionName) { | 
                                                        
| 184 | 184 | $value = LAGAdminBundle::LOAD_STRATEGY_NONE;  | 
                                                        
@@ -201,7 +201,7 @@ discard block  | 
                                                    ||
| 201 | 201 | */  | 
                                                        
| 202 | 202 | protected function getCriteriaNormalizer()  | 
                                                        
| 203 | 203 |      { | 
                                                        
| 204 | -        return function (Options $options, $value) { | 
                                                        |
| 204 | +        return function(Options $options, $value) { | 
                                                        |
| 205 | 205 |              if (!$value) { | 
                                                        
| 206 | 206 | $idActions = [  | 
                                                        
| 207 | 207 | 'edit',  | 
                                                        
@@ -239,7 +239,7 @@ discard block  | 
                                                    ||
| 239 | 239 | */  | 
                                                        
| 240 | 240 | protected function getFiltersNormalizer(): Closure  | 
                                                        
| 241 | 241 |      { | 
                                                        
| 242 | -        return function (Options $options, $data) { | 
                                                        |
| 242 | +        return function(Options $options, $data) { | 
                                                        |
| 243 | 243 | $normalizedData = [];  | 
                                                        
| 244 | 244 | |
| 245 | 245 |              foreach ($data as $name => $field) { | 
                                                        
@@ -265,7 +265,7 @@ discard block  | 
                                                    ||
| 265 | 265 | |
| 266 | 266 | protected function getFormNormalizer(): Closure  | 
                                                        
| 267 | 267 |      { | 
                                                        
| 268 | -        return function (Options $options, $value) { | 
                                                        |
| 268 | +        return function(Options $options, $value) { | 
                                                        |
| 269 | 269 |              if (null !== $value) { | 
                                                        
| 270 | 270 | return $value;  | 
                                                        
| 271 | 271 | }  | 
                                                        
@@ -285,7 +285,7 @@ discard block  | 
                                                    ||
| 285 | 285 | |
| 286 | 286 | protected function getTitleNormalizer(): Closure  | 
                                                        
| 287 | 287 |      { | 
                                                        
| 288 | -        return function (Options $options, $value) { | 
                                                        |
| 288 | +        return function(Options $options, $value) { | 
                                                        |
| 289 | 289 | // If the translation system is not used, return the provided value as is  | 
                                                        
| 290 | 290 |              if (!$this->adminConfiguration->isTranslationEnabled()) { | 
                                                        
| 291 | 291 |                  if (null === $value) { | 
                                                        
@@ -358,7 +358,7 @@ discard block  | 
                                                    ||
| 358 | 358 | 'menus' => [],  | 
                                                        
| 359 | 359 | ])  | 
                                                        
| 360 | 360 |              ->setAllowedTypes('add_return', 'boolean') | 
                                                        
| 361 | -            ->setNormalizer('menus', function (Options $options, $value) { | 
                                                        |
| 361 | +            ->setNormalizer('menus', function(Options $options, $value) { | 
                                                        |
| 362 | 362 |                  if (false === $value) { | 
                                                        
| 363 | 363 | return $value;  | 
                                                        
| 364 | 364 | }  | 
                                                        
@@ -429,7 +429,7 @@ discard block  | 
                                                    ||
| 429 | 429 |              ->setAllowedTypes('route_path', 'string') | 
                                                        
| 430 | 430 |              ->setAllowedTypes('route_defaults', 'array') | 
                                                        
| 431 | 431 |              ->setAllowedTypes('route_requirements', 'array') | 
                                                        
| 432 | -            ->setNormalizer('route_defaults', function (Options $options, $value) { | 
                                                        |
| 432 | +            ->setNormalizer('route_defaults', function(Options $options, $value) { | 
                                                        |
| 433 | 433 |                  if (!$value || is_array($value)) { | 
                                                        
| 434 | 434 | $value = [];  | 
                                                        
| 435 | 435 | }  | 
                                                        
@@ -14,7 +14,7 @@  | 
                                                    ||
| 14 | 14 | $environment = $this->createMock(Environment::class);  | 
                                                        
| 15 | 15 | $registry = new ScriptRegistry($environment);  | 
                                                        
| 16 | 16 | |
| 17 | -        $this->assertExceptionRaised(Exception::class, function () use ($registry) { | 
                                                        |
| 17 | +        $this->assertExceptionRaised(Exception::class, function() use ($registry) { | 
                                                        |
| 18 | 18 |              $registry->unregister('footer', 'test.js'); | 
                                                        
| 19 | 19 | });  | 
                                                        
| 20 | 20 | |
@@ -154,7 +154,7 @@  | 
                                                    ||
| 154 | 154 | ['page_parameter', 'page'],  | 
                                                        
| 155 | 155 | ]);  | 
                                                        
| 156 | 156 | |
| 157 | - $provider->get($admin, 42);  | 
                                                        |
| 157 | + $provider->get($admin, 42);  | 
                                                        |
| 158 | 158 | }  | 
                                                        
| 159 | 159 | |
| 160 | 160 | public function testSaveItem()  | 
                                                        
@@ -46,7 +46,7 @@  | 
                                                    ||
| 46 | 46 | public function testResolveOptionsWithMissingAction()  | 
                                                        
| 47 | 47 |      { | 
                                                        
| 48 | 48 | $adminConfiguration = $this->createAdminConfigurationMock([  | 
                                                        
| 49 | - ['actions', [],],  | 
                                                        |
| 49 | + ['actions', [], ],  | 
                                                        |
| 50 | 50 | ]);  | 
                                                        
| 51 | 51 | |
| 52 | 52 |          $configuration = new ActionConfiguration('my_action', 'my_admin', $adminConfiguration); | 
                                                        
@@ -80,7 +80,7 @@ discard block  | 
                                                    ||
| 80 | 80 | );  | 
                                                        
| 81 | 81 | $request = new Request();  | 
                                                        
| 82 | 82 | |
| 83 | -        $this->assertExceptionRaised(Exception::class, function () use ($admin) { | 
                                                        |
| 83 | +        $this->assertExceptionRaised(Exception::class, function() use ($admin) { | 
                                                        |
| 84 | 84 | $admin->getRequest();  | 
                                                        
| 85 | 85 | });  | 
                                                        
| 86 | 86 | |
@@ -100,7 +100,7 @@ discard block  | 
                                                    ||
| 100 | 100 | $this->assertCount(1, $admin->getForms());  | 
                                                        
| 101 | 101 | $this->assertEquals($form, $admin->getForms()['entity']);  | 
                                                        
| 102 | 102 |          $this->assertEquals($form, $admin->getForm('entity')); | 
                                                        
| 103 | -        $this->assertExceptionRaised(Exception::class, function () use ($admin) { | 
                                                        |
| 103 | +        $this->assertExceptionRaised(Exception::class, function() use ($admin) { | 
                                                        |
| 104 | 104 |              $admin->getForm('invalid'); | 
                                                        
| 105 | 105 | });  | 
                                                        
| 106 | 106 | }  | 
                                                        
@@ -108,7 +108,7 @@ discard block  | 
                                                    ||
| 108 | 108 | public function getHandleRequestProvider(): array  | 
                                                        
| 109 | 109 |      { | 
                                                        
| 110 | 110 | return [  | 
                                                        
| 111 | - [['test',],],  | 
                                                        |
| 111 | + [['test', ], ],  | 
                                                        |
| 112 | 112 | [[]]  | 
                                                        
| 113 | 113 | ];  | 
                                                        
| 114 | 114 | }  | 
                                                        
@@ -20,7 +20,7 @@  | 
                                                    ||
| 20 | 20 | |
| 21 | 21 | $this->assertEquals($admin, $helper->getCurrent());  | 
                                                        
| 22 | 22 | |
| 23 | -        $this->assertExceptionRaised(Exception::class, function () use ($helper, $admin) { | 
                                                        |
| 23 | +        $this->assertExceptionRaised(Exception::class, function() use ($helper, $admin) { | 
                                                        |
| 24 | 24 | $helper->setCurrent($admin);  | 
                                                        
| 25 | 25 | });  | 
                                                        
| 26 | 26 | }  | 
                                                        
@@ -30,7 +30,7 @@  | 
                                                    ||
| 30 | 30 | |
| 31 | 31 | public function testBuildMenu()  | 
                                                        
| 32 | 32 |      { | 
                                                        
| 33 | - list($subscriber, , $menuFactory, $eventDispatcher) = $this->createSubscriber([  | 
                                                        |
| 33 | + list($subscriber,, $menuFactory, $eventDispatcher) = $this->createSubscriber([  | 
                                                        |
| 34 | 34 | 'my_little_menu' => [],  | 
                                                        
| 35 | 35 | ], [  | 
                                                        
| 36 | 36 | ['enable_menus', true],  |