Implements hook_module_implements_alter().

Fichier

advagg_mod/advagg_mod.module, line 240

Code

function advagg_mod_module_implements_alter(&$implementations, $hook) {
    // Move advagg_mod to the top.
    if ($hook === 'library_alter' && array_key_exists('advagg_mod', $implementations)) {
        $item = array(
            'advagg_mod' => $implementations['advagg_mod'],
        );
        unset($implementations['advagg_mod']);
        $implementations = array_merge($item, $implementations);
    }
    // Remove advagg_mod. Function gets called directly.
    if ($hook === 'html_head_alter' && array_key_exists('advagg_mod', $implementations)) {
        unset($implementations['advagg_mod']);
    }
    // Move advagg_mod_css_post_alter to the bottom.
    if ($hook === 'css_post_alter' && array_key_exists('advagg_mod', $implementations)) {
        $item = $implementations['advagg_mod'];
        unset($implementations['advagg_mod']);
        $implementations['advagg_mod'] = $item;
    }
    // Move advagg_mod_js_post_alter to the bottom.
    if ($hook === 'js_post_alter' && array_key_exists('advagg_mod', $implementations)) {
        $item = $implementations['advagg_mod'];
        unset($implementations['advagg_mod']);
        $implementations['advagg_mod'] = $item;
    }
}