Total Complexity | 4 |
Total Lines | 23 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
8 | class CleanCommand extends Command |
||
9 | { |
||
10 | protected $signature = 'visits:clean'; |
||
11 | protected $description = '(Laravel-Visits) Clean expired keys and visits.'; |
||
12 | |||
13 | |||
14 | public function __construct() |
||
15 | { |
||
16 | parent::__construct(); |
||
17 | } |
||
18 | |||
19 | public function handle() |
||
20 | { |
||
21 | $currentEngine = config('visits.engine') ?? ''; |
||
22 | |||
23 | if($currentEngine == 'eloquent') { |
||
24 | $this->cleanEloquent(); |
||
25 | } |
||
26 | } |
||
27 | |||
28 | protected function cleanEloquent() |
||
31 | } |
||
32 | } |
||
33 |