1 | <?php |
||
2 | |||
3 | namespace Elgg\Cli; |
||
4 | |||
5 | /** |
||
6 | * elgg-cli flush |
||
7 | */ |
||
8 | class FlushCommand extends Command { |
||
9 | |||
10 | /** |
||
11 | * {@inheritdoc} |
||
12 | */ |
||
13 | protected function configure() { |
||
14 | $this->setName('flush') |
||
15 | ->setDescription('Flush all caches (deprecated: use "elgg-cli cache:clear")'); |
||
16 | } |
||
17 | |||
18 | /** |
||
19 | * {@inheritdoc} |
||
20 | */ |
||
21 | protected function command() { |
||
22 | elgg_deprecated_notice('"elgg-cli flush" has been deprecated, use "elgg-cli cache:clear"', '3.3'); |
||
23 | |||
24 | elgg_flush_caches(); |
||
1 ignored issue
–
show
|
|||
25 | |||
26 | if (!$this->option('quiet')) { |
||
27 | $this->write('System caches have been flushed'); |
||
28 | } |
||
29 | |||
30 | return 0; |
||
31 | } |
||
32 | } |
||
33 |
This function has been deprecated. The supplier of the function has supplied an explanatory message.
The explanatory message should give you some clue as to whether and when the function will be removed and what other function to use instead.