summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDries Buytaert2004-12-01 12:09:56 +0000
committerDries Buytaert2004-12-01 12:09:56 +0000
commit20a1e3edcb11a3cd6a5ad3c536a34398d3a00386 (patch)
treef6f340c5fca68ba421cd6693a1fed11b03849c26
parent995277f41a69848bb902a9828bdb813755043304 (diff)
- Patch #13405 by Moshe: make you actually do something useful with the init hook. A recent patch to 4.5 and HEAD made this patch run too early in the request (for non-cached pages).4.5.1
-rw-r--r--includes/bootstrap.inc3
-rw-r--r--includes/module.inc3
2 files changed, 2 insertions, 4 deletions
diff --git a/includes/bootstrap.inc b/includes/bootstrap.inc
index 63c331a..014fc27 100644
--- a/includes/bootstrap.inc
+++ b/includes/bootstrap.inc
@@ -230,11 +230,10 @@ function drupal_page_header() {
if (variable_get('dev_timer', 0)) {
timer_start();
}
- bootstrap_invoke_all('init');
if (variable_get('cache', 0)) {
if ($cache = page_get_cache()) {
-
+ bootstrap_invoke_all('init');
// Set default values:
$date = gmdate('D, d M Y H:i:s', $cache->created) .' GMT';
$etag = '"'. md5($date) .'"';
diff --git a/includes/module.inc b/includes/module.inc
index 95e3b87..928bed9 100644
--- a/includes/module.inc
+++ b/includes/module.inc
@@ -9,11 +9,10 @@
/**
* Initialize all modules.
*
- * To change the required set of modules, change this function as well as
- * system_listing() and module_list().
*/
function module_init() {
module_load_all();
+ module_invoke_all('init');
}
/**