function drush_advagg_cron in Advanced CSS/JS Aggregation 8.3
Same name and namespace in other branches
- 8.4 advagg.drush.inc \drush_advagg_cron()
- 8.2 advagg.drush.inc \drush_advagg_cron()
- 7.2 advagg.drush.inc \drush_advagg_cron()
Callback function for drush advagg-cron.
Related topics
File
- ./
advagg.drush.inc, line 154 - Drush commands for Advanced CSS/JS Aggregation.
Code
function drush_advagg_cron() {
// Run AdvAgg cron job.
$output = advagg_cron(TRUE);
if (!empty($output['css']) || !empty($output['js'])) {
drush_log(dt('All stale aggregates have been deleted. %css_count CSS files and %js_count JS files have been removed.', [
'%css_count' => count($output['css']),
'%js_count' => count($output['js']),
]), 'ok');
}
else {
drush_log(dt('No stale aggregates found. Nothing was deleted.'), 'ok');
}
}