Delete all empty advagg aggregated files.

Sujets associés

1 string reference to 'advagg_delete_empty_aggregates_button'
advagg_admin_operations_form dans ./advagg.admin.inc
Form builder; Do advagg operations.

Fichier

./advagg.admin.inc, line 1687

Code

function advagg_delete_empty_aggregates_button() {
    // Run the command.
    module_load_include('inc', 'advagg', 'advagg.cache');
    list($css_files, $js_files) = advagg_delete_empty_aggregates();
    // Report back the results.
    if (count($css_files) > 0 || count($js_files) > 0) {
        drupal_set_message(t('All empty aggregates have been deleted. %css_count CSS files and %js_count JS files have been removed.', array(
            '%css_count' => count($css_files),
            '%js_count' => count($js_files),
        )));
    }
    else {
        drupal_set_message(t('No empty aggregates found. Nothing was deleted.'));
    }
}