function composer_autoload_init in Composer Autoload 6
Same name and namespace in other branches
- 7 composer_autoload.module \composer_autoload_init()
Implements hook_init().
File
- ./
composer_autoload.module, line 13 - Provides primary Drupal hook implementations.
Code
function composer_autoload_init() {
// Check for cached list of loaders, otherwise rebuild list.
if ($loaders = cache_get('composer_autoload')) {
$loaders = $loaders->data;
}
else {
$loaders = composer_autoload_cache_rebuild();
}
// Include each autoload.php file.
foreach ($loaders as $loader) {
include $loader;
}
}