function _system_update_bootstrap_status
_system_update_bootstrap_status()
Refresh bootstrap column in the system table.
This is called internally by module_enable/disable() to flag modules that implement hooks used during bootstrap, such as hook_boot(). These modules are loaded earlier to invoke the hooks.
File
- modules/system/system.module, line 2481
- Configuration system that lets administrators modify the workings of the site.
Code
function _system_update_bootstrap_status() { $bootstrap_modules = array(); foreach (bootstrap_hooks() as $hook) { foreach (module_implements($hook) as $module) { $bootstrap_modules[] = $module; } } $query = db_update('system')->fields(array('bootstrap' => 0)); if ($bootstrap_modules) { db_update('system') ->fields(array('bootstrap' => 1)) ->condition('name', $bootstrap_modules, 'IN') ->execute(); $query->condition('name', $bootstrap_modules, 'NOT IN'); } $query->execute(); // Reset the cached list of bootstrap modules. system_list_reset(); }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!system!system.module/function/_system_update_bootstrap_status/7.x