Completed
Push — master ( 16d4f5...bb9182 )
by Alexander
11s
created
src/Module.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@
 block discarded – undo
36 36
         /** @var AspectContainer $aspectContainer */
37 37
         $aspectContainer = $serviceManager->get(AspectContainer::class);
38 38
         $config          = $serviceManager->get('config');
39
-        $listOfAspects   = $config['goaop_aspect'];
39
+        $listOfAspects   = $config[ 'goaop_aspect' ];
40 40
         foreach ($listOfAspects as $aspectService) {
41 41
             $aspect = $serviceManager->get($aspectService);
42 42
             $aspectContainer->registerAspect($aspect);
Please login to merge, or discard this patch.
src/Factory/AspectKernelFactory.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
     public function createService(ServiceLocatorInterface $serviceLocator)
28 28
     {
29 29
         $aspectKernel = AspectZf2Kernel::getInstance();
30
-        $aspectKernel->init($serviceLocator->get('config')['goaop_module']);
30
+        $aspectKernel->init($serviceLocator->get('config')[ 'goaop_module' ]);
31 31
 
32 32
         return $aspectKernel;
33 33
     }
Please login to merge, or discard this patch.
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
      * @param string             $requestedName
28 28
      * @param array              $options
29 29
      *
30
-     * @return mixed
30
+     * @return AspectZf2Kernel
31 31
      */
32 32
     public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
33 33
     {
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
      *
40 40
      * @param ServiceLocatorInterface $serviceLocator
41 41
      *
42
-     * @return mixed
42
+     * @return AspectZf2Kernel
43 43
      */
44 44
     public function createService(ServiceLocatorInterface $serviceLocator)
45 45
     {
Please login to merge, or discard this patch.
src/Console/Warmup/Zf2WarmupCommand.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -60,11 +60,11 @@  discard block
 block discarded – undo
60 60
         $kernel  = AspectKernel::getInstance();
61 61
         $options = $kernel->getOptions();
62 62
 
63
-        if (empty($options['cacheDir'])) {
63
+        if (empty($options[ 'cacheDir' ])) {
64 64
             throw new \InvalidArgumentException('Cache warmer require the `cacheDir` options to be configured');
65 65
         }
66 66
 
67
-        $enumerator = new Enumerator($options['appDir'], $options['includePaths'], $options['excludePaths']);
67
+        $enumerator = new Enumerator($options[ 'appDir' ], $options[ 'includePaths' ], $options[ 'excludePaths' ]);
68 68
         $iterator   = $enumerator->enumerate();
69 69
 
70 70
         $totalFiles = iterator_count($iterator);
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
         });
77 77
 
78 78
         $index  = 0;
79
-        $errors = [];
79
+        $errors = [ ];
80 80
         foreach ($iterator as $file) {
81 81
             if ($output->getVerbosity() >= OutputInterface::VERBOSITY_VERBOSE) {
82 82
                 $output->writeln("Processing file <info>{$file->getRealPath()}</info>");
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
                 $isSuccess = true;
93 93
             } catch (\Exception $e) {
94 94
                 $isSuccess = false;
95
-                $errors[$file->getRealPath()] = $e;
95
+                $errors[ $file->getRealPath() ] = $e;
96 96
             }
97 97
             if ($output->getVerbosity() == OutputInterface::VERBOSITY_NORMAL) {
98 98
                 $output->write($isSuccess ? '.' : '<error>E</error>');
Please login to merge, or discard this patch.
config/module.config.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
      | AOP will check this list to apply an AOP to selected directories only,
73 73
      | leave it empty if you want AOP to be applied to all files in the appDir
74 74
      */
75
-    'includePaths' => [],
75
+    'includePaths' => [ ],
76 76
 
77 77
     /*
78 78
      |--------------------------------------------------------------------------
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
      |
82 82
      | AOP will check this list to disable AOP for selected directories
83 83
      */
84
-    'excludePaths' => [],
84
+    'excludePaths' => [ ],
85 85
 
86 86
     /**
87 87
      |--------------------------------------------------------------------------
@@ -101,5 +101,5 @@  discard block
 block discarded – undo
101 101
             AspectContainer::class => AspectContainerFactory::class,
102 102
         ]
103 103
     ],
104
-    'goaop_aspect' => []
104
+    'goaop_aspect' => [ ]
105 105
 ];
Please login to merge, or discard this patch.
tests/resources/goaop_module.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@
 block discarded – undo
6 6
     'cacheDir'       => __DIR__,
7 7
     'cacheFileMode'  => 0770 & ~umask(),
8 8
     'features'       => 0,
9
-    'includePaths'   => [],
10
-    'excludePaths'   => [],
9
+    'includePaths'   => [ ],
10
+    'excludePaths'   => [ ],
11 11
     'containerClass' => \Go\Core\GoAspectContainer::class,
12 12
 ];
Please login to merge, or discard this patch.
tests/Unit/ModuleTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
         $eventManager = $this->prophesize(EventManagerInterface::class);
42 42
         $eventManager->attach(
43 43
             Argument::exact(ModuleEvent::EVENT_LOAD_MODULES_POST),
44
-            Argument::exact([$module, 'initializeAspects'])
44
+            Argument::exact([ $module, 'initializeAspects' ])
45 45
         )->shouldBeCalled();
46 46
 
47 47
         $moduleManager = $this->prophesize(ModuleManagerInterface::class);
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
             ->willReturn($aspectContainer->reveal())
67 67
             ->shouldBeCalled();
68 68
         $serviceManager->get('config')
69
-            ->willReturn(['goaop_aspect' => ['testAspect']])
69
+            ->willReturn([ 'goaop_aspect' => [ 'testAspect' ] ])
70 70
             ->shouldBeCalled();
71 71
         $serviceManager->get('testAspect')
72 72
             ->willReturn($aspect)
Please login to merge, or discard this patch.
tests/Unit/Factory/AspectKernelFactoryTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
     {
20 20
         $serviceLocator = $this->prophesize(ServiceLocatorInterface::class);
21 21
         $serviceLocator->get('config')
22
-            ->willReturn(['goaop_module' => require __DIR__ . '/../../resources/goaop_module.php'])
22
+            ->willReturn([ 'goaop_module' => require __DIR__ . '/../../resources/goaop_module.php' ])
23 23
             ->shouldBeCalled();
24 24
 
25 25
         $factory = new AspectKernelFactory();
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
     {
41 41
         $serviceLocator = $this->prophesize(ServiceLocatorInterface::class);
42 42
         $serviceLocator->get('config')
43
-            ->willReturn(['goaop_module' => require __DIR__ . '/../../resources/goaop_module.php'])
43
+            ->willReturn([ 'goaop_module' => require __DIR__ . '/../../resources/goaop_module.php' ])
44 44
             ->shouldBeCalled();
45 45
 
46 46
         $factory = new AspectKernelFactory();
Please login to merge, or discard this patch.
src/Factory/AspectContainerFactory.php 1 patch
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
      * @param string             $requestedName
28 28
      * @param array              $options
29 29
      *
30
-     * @return mixed
30
+     * @return null|\Go\Core\AspectContainer
31 31
      */
32 32
     public function __invoke(ContainerInterface $container, $requestedName, array $options = null)
33 33
     {
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
      *
40 40
      * @param ServiceLocatorInterface $serviceLocator
41 41
      *
42
-     * @return mixed
42
+     * @return null|\Go\Core\AspectContainer
43 43
      */
44 44
     public function createService(ServiceLocatorInterface $serviceLocator)
45 45
     {
Please login to merge, or discard this patch.