Conditions | 3 |
Paths | 3 |
Total Lines | 13 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 12 |
Changes | 0 |
1 | <?php |
||
38 | public function handle() |
||
39 | { |
||
40 | $filesystem = app(Filesystem::class); |
||
41 | |||
42 | $logFiles = $filesystem->glob(storage_path('logs/*.log')); |
||
43 | |||
44 | foreach ($logFiles as $file) { |
||
45 | $status = $filesystem->delete($file); |
||
46 | if ($status) { |
||
47 | $this->info('Successfully deleted: ' . $file); |
||
48 | } |
||
49 | } |
||
50 | } |
||
51 | |||
53 |