Conditions | 4 |
Paths | 4 |
Total Lines | 27 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
13 | public function handle() |
||
14 | { |
||
15 | if (app()->environment() != 'local') { |
||
|
|||
16 | throw new \Exception('Aborting. This command is dangerous and only meant for your local environment.'); |
||
17 | } |
||
18 | |||
19 | if ($this->option('reset')) { |
||
20 | if (! $this->confirm('You are about to force reset the database in the ' . app()->environment() . ' environment! ARE YOU SURE?')) { |
||
21 | $this->info('aborting.'); |
||
22 | |||
23 | return; |
||
24 | } |
||
25 | } |
||
26 | |||
27 | // loop over all managed models |
||
28 | |||
29 | // reset entries if requested |
||
30 | |||
31 | // Add 10 dummy entries + make sure to enter page fragments as well. |
||
32 | |||
33 | // Include Our Chief factories for this command |
||
34 | // app(ModelFactory::class)->load(realpath(dirname(__DIR__) . '/../database/factories')); |
||
35 | // |
||
36 | // $this->info('Scaffolding some entries...'); |
||
37 | // factory(Page::class, 5)->create(); |
||
38 | |||
39 | $this->info('Great. We\'re done here. NOW START HACKING!'); |
||
40 | } |
||
42 |