Completed
Push — master ( 550846...8c8483 )
by Anton
09:53
created
src/Command/Generate/ControllerCommand.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -7,7 +7,6 @@
 block discarded – undo
7 7
 namespace Bluzman\Command\Generate;
8 8
 
9 9
 use Bluzman\Generator;
10
-use Bluzman\Input\InputException;
11 10
 use Symfony\Component\Console\Input\ArrayInput;
12 11
 use Symfony\Component\Console\Input\InputInterface;
13 12
 use Symfony\Component\Console\Output\OutputInterface;
Please login to merge, or discard this patch.
src/Command/Generate/ModuleCommand.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -105,8 +105,8 @@
 block discarded – undo
105 105
     }
106 106
 
107 107
     /**
108
-     * @param $path
109
-     * @param array $subFolders
108
+     * @param string $path
109
+     * @param string[] $subFolders
110 110
      */
111 111
     protected function addSubFolders($path, array $subFolders = [])
112 112
     {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@
 block discarded – undo
38 38
 
39 39
         $controller = new InputArgument(
40 40
             'controller',
41
-            InputArgument::OPTIONAL|InputArgument::IS_ARRAY,
41
+            InputArgument::OPTIONAL | InputArgument::IS_ARRAY,
42 42
             'Controller name(s)'
43 43
         );
44 44
 
Please login to merge, or discard this patch.
src/Command/Generate/RestCommand.php 2 patches
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -6,8 +6,6 @@
 block discarded – undo
6 6
 
7 7
 namespace Bluzman\Command\Generate;
8 8
 
9
-use Bluz\Validator\Validator as v;
10
-use Bluzman\Input\InputArgument;
11 9
 use Bluzman\Input\InputException;
12 10
 use Bluzman\Generator;
13 11
 use Symfony\Component\Console\Input\InputInterface;
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -54,14 +54,14 @@  discard block
 block discarded – undo
54 54
 
55 55
             if (!$this->getApplication()->isModelExists($model)) {
56 56
                 throw new InputException(
57
-                    "Model $model is not exist, ".
57
+                    "Model $model is not exist, " .
58 58
                     "run command <question>bluzman generate:model $model</question> before");
59 59
             }
60 60
 
61
-            $crudPath = $this->getApplication()->getModelPath($model) .DS. 'Crud.php';
61
+            $crudPath = $this->getApplication()->getModelPath($model) . DS . 'Crud.php';
62 62
             if (!is_file($crudPath)) {
63 63
                 throw new InputException(
64
-                    "CRUD for $model is not exist, ".
64
+                    "CRUD for $model is not exist, " .
65 65
                     "run command <question>bluzman generate:crud $model</question> before");
66 66
             }
67 67
 
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
 
71 71
             if (!$this->getApplication()->isModuleExists($module)) {
72 72
                 throw new InputException(
73
-                    "Module $module is not exist, ".
73
+                    "Module $module is not exist, " .
74 74
                     "run command <question>bluzman generate:module $module</question> before");
75 75
             }
76 76
 
@@ -96,8 +96,8 @@  discard block
 block discarded – undo
96 96
      */
97 97
     protected function generate(InputInterface $input, OutputInterface $output)
98 98
     {
99
-        $model= ucfirst($input->getArgument('model'));
100
-        $module= $input->getArgument('module');
99
+        $model = ucfirst($input->getArgument('model'));
100
+        $module = $input->getArgument('module');
101 101
 
102 102
         $this->write("Generate <info>$module/controllers/rest.php</info>");
103 103
 
Please login to merge, or discard this patch.
src/Command/Server/StartCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@
 block discarded – undo
49 49
      */
50 50
     protected function execute(InputInterface $input, OutputInterface $output)
51 51
     {
52
-        $this->info('Running "server:start" command ... [' . $input->getOption('env'). ']');
52
+        $this->info('Running "server:start" command ... [' . $input->getOption('env') . ']');
53 53
 
54 54
         $host = $input->getOption('host');
55 55
         $port = $input->getOption('port');
Please login to merge, or discard this patch.
src/Command/Generate/AbstractGenerateCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@
 block discarded – undo
88 88
      */
89 89
     protected function getTemplate($class)
90 90
     {
91
-        $class = '\\Bluzman\\Generator\\Template\\' . $class ;
91
+        $class = '\\Bluzman\\Generator\\Template\\' . $class;
92 92
         return new $class;
93 93
     }
94 94
 
Please login to merge, or discard this patch.
src/Command/Generate/CrudCommand.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
 
67 67
             if (!$this->getApplication()->isModelExists($model)) {
68 68
                 throw new InputException(
69
-                    "Model $model is not exist, ".
69
+                    "Model $model is not exist, " .
70 70
                     "run command <question>bluzman generate:model $model</question> before");
71 71
             }
72 72
 
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 
76 76
                 if (!$this->getApplication()->isModuleExists($module)) {
77 77
                     throw new InputException(
78
-                        "Module $module is not exist, ".
78
+                        "Module $module is not exist, " .
79 79
                         "run command <question>bluzman generate:module $module</question> before");
80 80
                 }
81 81
             }
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
         $model = ucfirst($input->getArgument('model'));
109 109
 
110 110
         // generate CRUD
111
-        $crudFile = $this->getApplication()->getModelPath($model) .DS. 'Crud.php';
111
+        $crudFile = $this->getApplication()->getModelPath($model) . DS . 'Crud.php';
112 112
 
113 113
         if (file_exists($crudFile)) {
114 114
             $this->comment("Crud file <info>$model/Crud.php</info> already exists");
Please login to merge, or discard this patch.
src/Command/Generate/GridCommand.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
 
67 67
             if (!$this->getApplication()->isModelExists($model)) {
68 68
                 throw new InputException(
69
-                    "Model $model is not exist, ".
69
+                    "Model $model is not exist, " .
70 70
                     "run command <question>bluzman generate:model $model</question> before");
71 71
             }
72 72
 
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 
76 76
                 if (!$this->getApplication()->isModuleExists($module)) {
77 77
                     throw new InputException(
78
-                        "Module $module is not exist, ".
78
+                        "Module $module is not exist, " .
79 79
                         "run command <question>bluzman generate:module $module</question> before");
80 80
                 }
81 81
             }
@@ -109,7 +109,7 @@  discard block
 block discarded – undo
109 109
         $model = ucfirst($input->getArgument('model'));
110 110
 
111 111
         // generate CRUD
112
-        $crudFile = $this->getApplication()->getModelPath($model) .DS. 'Grid.php';
112
+        $crudFile = $this->getApplication()->getModelPath($model) . DS . 'Grid.php';
113 113
 
114 114
         if (file_exists($crudFile)) {
115 115
             $this->comment("Crud file <info>$model/Grid.php</info> already exists");
Please login to merge, or discard this patch.
src/Command/Generate/ModelCommand.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
         }
101 101
 
102 102
         // generate table
103
-        $tableFile = $this->getApplication()->getModelPath($modelName) .DS. 'Table.php';
103
+        $tableFile = $this->getApplication()->getModelPath($modelName) . DS . 'Table.php';
104 104
 
105 105
         if (file_exists($tableFile)) {
106 106
             $this->comment("Table file <info>$modelName/Table.php</info> already exists");
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
         }
119 119
 
120 120
         // generate row
121
-        $rowFile = $this->getApplication()->getModelPath($modelName) .DS. 'Row.php';
121
+        $rowFile = $this->getApplication()->getModelPath($modelName) . DS . 'Row.php';
122 122
 
123 123
         if (file_exists($rowFile)) {
124 124
             $this->comment("Row file <info>$modelName/Row.php</info> already exists");
Please login to merge, or discard this patch.