Code Duplication    Length = 8-8 lines in 3 locations

src/Commands/ResourceCommand.php 3 locations

@@ 99-106 (lines=8) @@
96
            ]);
97
98
            // Make a datatable
99
            if (is_array($abilities) && in_array('viewAny', $abilities)) {
100
                $this->call('microboard:datatable', [
101
                    'name' => $modelName,
102
                    '--model' => trim($model, '/\\'),
103
                    '--columns' => $this->getModelFillableColumns($model),
104
                    '--base_path' => $this->option('base_path')
105
                ]);
106
            }
107
108
            // Make a store form request
109
            if (is_array($abilities) && in_array('create', $abilities)) {
@@ 109-116 (lines=8) @@
106
            }
107
108
            // Make a store form request
109
            if (is_array($abilities) && in_array('create', $abilities)) {
110
                $this->call('microboard:request', [
111
                    'name' => "{$modelName}\\StoreFormRequest",
112
                    '--model' => $model,
113
                    '--columns' => $this->getModelFillableColumns($model),
114
                    '--base_path' => $this->option('base_path')
115
                ]);
116
            }
117
118
            // Make a update form request
119
            if (is_array($abilities) && in_array('update', $abilities)) {
@@ 119-126 (lines=8) @@
116
            }
117
118
            // Make a update form request
119
            if (is_array($abilities) && in_array('update', $abilities)) {
120
                $this->call('microboard:request', [
121
                    'name' => "{$modelName}\\UpdateFormRequest",
122
                    '--model' => $model,
123
                    '--columns' => $this->getModelFillableColumns($model),
124
                    '--base_path' => $this->option('base_path')
125
                ]);
126
            }
127
        }
128
129
        // Make views and lang