Completed
Pull Request — master (#275)
by
unknown
04:25
created
src/Commands/CommandCommand.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
     }
60 60
 
61 61
     /**
62
-     * @return mixed
62
+     * @return string
63 63
      */
64 64
     protected function getTemplateContents()
65 65
     {
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
     }
74 74
 
75 75
     /**
76
-     * @return mixed
76
+     * @return string
77 77
      */
78 78
     protected function getDestinationFilePath()
79 79
     {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@
 block discarded – undo
81 81
 
82 82
         $seederPath = $this->laravel['modules']->config('paths.generator.command');
83 83
 
84
-        return $path . $seederPath . '/' . $this->getFileName() . '.php';
84
+        return $path.$seederPath.'/'.$this->getFileName().'.php';
85 85
     }
86 86
 
87 87
     /**
Please login to merge, or discard this patch.
src/Commands/ModelCommand.php 2 patches
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
     }
60 60
 
61 61
     /**
62
-     * @return mixed
62
+     * @return string
63 63
      */
64 64
     protected function getTemplateContents()
65 65
     {
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
     }
79 79
 
80 80
     /**
81
-     * @return mixed
81
+     * @return string
82 82
      */
83 83
     protected function getDestinationFilePath()
84 84
     {
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
     }
91 91
 
92 92
     /**
93
-     * @return mixed|string
93
+     * @return string
94 94
      */
95 95
     private function getModelName()
96 96
     {
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
     private function handleOptionalMigrationOption()
73 73
     {
74 74
         if ($this->option('migration') === true) {
75
-            $migrationName = 'create_' . strtolower($this->argument('model')) . '_table';
75
+            $migrationName = 'create_'.strtolower($this->argument('model')).'_table';
76 76
             $this->call('module:make-migration', ['name' => $migrationName, 'module' => $this->argument('module')]);
77 77
         }
78 78
     }
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
 
106 106
         $seederPath = $this->laravel['modules']->config('paths.generator.model');
107 107
 
108
-        return $path . $seederPath . '/' . $this->getModelName() . '.php';
108
+        return $path.$seederPath.'/'.$this->getModelName().'.php';
109 109
     }
110 110
 
111 111
     /**
Please login to merge, or discard this patch.
src/Publishing/Publisher.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@
 block discarded – undo
88 88
     /**
89 89
      * Get module instance.
90 90
      *
91
-     * @return \Nwidart\Modules\Module
91
+     * @return string
92 92
      */
93 93
     public function getModule()
94 94
     {
Please login to merge, or discard this patch.
src/Collection.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
      */
25 25
     public function toArray()
26 26
     {
27
-        return array_map(function ($value) {
27
+        return array_map(function($value) {
28 28
             if ($value instanceof Module) {
29 29
                 return $value->json()->getAttributes();
30 30
             }
Please login to merge, or discard this patch.
src/Repository.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
      */
176 176
     public function getCached()
177 177
     {
178
-        return $this->app['cache']->remember($this->config('cache.key'), $this->config('cache.lifetime'), function () {
178
+        return $this->app['cache']->remember($this->config('cache.key'), $this->config('cache.lifetime'), function() {
179 179
             return $this->toCollection()->toArray();
180 180
         });
181 181
     }
@@ -263,7 +263,7 @@  discard block
 block discarded – undo
263 263
     {
264 264
         $modules = $this->enabled();
265 265
 
266
-        uasort($modules, function (Module $a, Module $b) use ($direction) {
266
+        uasort($modules, function(Module $a, Module $b) use ($direction) {
267 267
             if ($a->order == $b->order) {
268 268
                 return 0;
269 269
             }
Please login to merge, or discard this patch.
Doc Comments   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
     /**
94 94
      * Get scanned modules paths.
95 95
      *
96
-     * @return array
96
+     * @return string[]
97 97
      */
98 98
     public function getScanPaths()
99 99
     {
@@ -413,7 +413,7 @@  discard block
 block discarded – undo
413 413
     /**
414 414
      * Get module path for a specific module.
415 415
      *
416
-     * @param $module
416
+     * @param string $module
417 417
      *
418 418
      * @return string
419 419
      */
@@ -441,7 +441,7 @@  discard block
 block discarded – undo
441 441
     /**
442 442
      * Get a specific config data from a configuration file.
443 443
      *
444
-     * @param $key
444
+     * @param string $key
445 445
      * @param null $default
446 446
      *
447 447
      * @return mixed
@@ -488,7 +488,7 @@  discard block
 block discarded – undo
488 488
     /**
489 489
      * Get module used for cli session.
490 490
      *
491
-     * @return string
491
+     * @return Module
492 492
      */
493 493
     public function getUsedNow()
494 494
     {
@@ -498,7 +498,7 @@  discard block
 block discarded – undo
498 498
     /**
499 499
      * Get used now.
500 500
      *
501
-     * @return string
501
+     * @return Module
502 502
      */
503 503
     public function getUsed()
504 504
     {
@@ -575,7 +575,7 @@  discard block
 block discarded – undo
575 575
      *
576 576
      * @param string $name
577 577
      *
578
-     * @return bool
578
+     * @return boolean|null
579 579
      */
580 580
     public function enable($name)
581 581
     {
@@ -587,7 +587,7 @@  discard block
 block discarded – undo
587 587
      *
588 588
      * @param string $name
589 589
      *
590
-     * @return bool
590
+     * @return boolean|null
591 591
      */
592 592
     public function disable($name)
593 593
     {
Please login to merge, or discard this patch.
src/Commands/GenerateProviderCommand.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
 
68 68
         $module = $this->laravel['modules']->findOrFail($this->getModuleName());
69 69
 
70
-        return (new Stub('/' . $stub . '.stub', [
70
+        return (new Stub('/'.$stub.'.stub', [
71 71
             'NAMESPACE'         => $this->getClassNamespace($module),
72 72
             'CLASS'             => $this->getClass(),
73 73
             'LOWER_NAME'        => $module->getLowerName(),
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
 
91 91
         $generatorPath = $this->laravel['modules']->config('paths.generator.provider');
92 92
 
93
-        return $path . $generatorPath . '/' . $this->getFileName() . '.php';
93
+        return $path.$generatorPath.'/'.$this->getFileName().'.php';
94 94
     }
95 95
 
96 96
     /**
Please login to merge, or discard this patch.
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
     }
60 60
 
61 61
     /**
62
-     * @return mixed
62
+     * @return string
63 63
      */
64 64
     protected function getTemplateContents()
65 65
     {
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
     }
74 74
 
75 75
     /**
76
-     * @return mixed
76
+     * @return string
77 77
      */
78 78
     protected function getDestinationFilePath()
79 79
     {
Please login to merge, or discard this patch.
src/Commands/GenerateListenerCommand.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
             "EVENTNAME" => $this->getEventName($module),
63 63
             "EVENTSHORTENEDNAME" => $this->option('event'),
64 64
             "CLASS" => $this->getClass(),
65
-            'DUMMYNAMESPACE' => $this->laravel->getNamespace() . "Events",
65
+            'DUMMYNAMESPACE' => $this->laravel->getNamespace()."Events",
66 66
         ]))->render();
67 67
     }
68 68
 
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
 
73 73
         $seederPath = $this->laravel['modules']->config('paths.generator.listener');
74 74
 
75
-        return $path . $seederPath . '/' . $this->getFileName() . '.php';
75
+        return $path.$seederPath.'/'.$this->getFileName().'.php';
76 76
     }
77 77
 
78 78
     /**
@@ -94,13 +94,13 @@  discard block
 block discarded – undo
94 94
 
95 95
     protected function getEventName(Module $module)
96 96
     {
97
-        return $this->getClassNamespace($module) . "\\" . config('modules.paths.generator.event') . "\\" . $this->option('event');
97
+        return $this->getClassNamespace($module)."\\".config('modules.paths.generator.event')."\\".$this->option('event');
98 98
     }
99 99
 
100 100
     private function getNamespace($module)
101 101
     {
102 102
         $namespace = str_replace('/', '\\', config('modules.paths.generator.listener'));
103 103
 
104
-        return $this->getClassNamespace($module) . "\\" . $namespace;
104
+        return $this->getClassNamespace($module)."\\".$namespace;
105 105
     }
106 106
 }
Please login to merge, or discard this patch.
src/Commands/GenerateRouteProviderCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -68,7 +68,7 @@
 block discarded – undo
68 68
 
69 69
         $generatorPath = $this->laravel['modules']->config('paths.generator.provider');
70 70
 
71
-        return $path . $generatorPath . '/' . $this->getFileName() . '.php';
71
+        return $path.$generatorPath.'/'.$this->getFileName().'.php';
72 72
     }
73 73
 
74 74
     /**
Please login to merge, or discard this patch.
src/Commands/MakeRequestCommand.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@
 block discarded – undo
72 72
 
73 73
         $seederPath = $this->laravel['modules']->config('paths.generator.request');
74 74
 
75
-        return $path . $seederPath . '/' . $this->getFileName() . '.php';
75
+        return $path.$seederPath.'/'.$this->getFileName().'.php';
76 76
     }
77 77
 
78 78
     /**
Please login to merge, or discard this patch.
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
     }
60 60
 
61 61
     /**
62
-     * @return mixed
62
+     * @return string
63 63
      */
64 64
     protected function getTemplateContents()
65 65
     {
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
     }
74 74
 
75 75
     /**
76
-     * @return mixed
76
+     * @return string
77 77
      */
78 78
     protected function getDestinationFilePath()
79 79
     {
Please login to merge, or discard this patch.