Code Duplication    Length = 8-8 lines in 3 locations

src/Commands/ResourceCommand.php 3 locations

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