You are here

function _bootstrap_carousel_insert_after_first_element in bootstrap_carousel 7

Helper function for re-ordering arrays (needed by theme_registry_alter).

1 call to _bootstrap_carousel_insert_after_first_element()
bootstrap_carousel_theme_registry_alter in ./bootstrap_carousel.module
Implements hook_theme_registry_alter().

File

./bootstrap_carousel.module, line 257
Bootstrap carousel module hooks.

Code

function _bootstrap_carousel_insert_after_first_element(&$a, $element) {
  if (is_array($a)) {
    $first_element = array_shift($a);
    array_unshift($a, $first_element, $element);
  }
}