summaryrefslogtreecommitdiff
path: root/update.php
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2009-01-19 10:46:52 +0000
committerDries Buytaert <dries@buytaert.net>2009-01-19 10:46:52 +0000
commitd20e4571215b379676bf95898232717b121ad95b (patch)
treeaa181045614138f925ccc74587a70c870e2f1ac1 /update.php
parent8cef09a7e6c970054d44117020afc88b5ee2bd41 (diff)
downloadbrdo-d20e4571215b379676bf95898232717b121ad95b.tar.gz
brdo-d20e4571215b379676bf95898232717b121ad95b.tar.bz2
- Patch #201122 by c960657, Moshe Weitzman: never write anonymous sessions, unless something has been written to . This is an important performance improvements -- as long as you use modules that use carefully. It might be good to report some analytics about this in the performance settings page so administrators can see if there is a 'broken' module.
Diffstat (limited to 'update.php')
-rw-r--r--update.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/update.php b/update.php
index ff8a63d69..6aec74f6b 100644
--- a/update.php
+++ b/update.php
@@ -293,7 +293,7 @@ function update_batch() {
// During the update, toggle site maintenance so that schema changes do not
// affect visiting users.
- $_SESSION['site_offline'] = variable_get('site_offline', FALSE);
+ drupal_set_session('site_offline', variable_get('site_offline', FALSE));
if ($_SESSION['site_offline'] == FALSE) {
variable_set('site_offline', TRUE);
}
@@ -327,9 +327,9 @@ function update_finished($success, $results, $operations) {
// clear the caches in case the data has been updated.
drupal_flush_all_caches();
- $_SESSION['update_results'] = $results;
- $_SESSION['update_success'] = $success;
- $_SESSION['updates_remaining'] = $operations;
+ drupal_set_session('update_results', $results);
+ drupal_set_session('update_success', $success);
+ drupal_set_session('updates_remaining', $operations);
// Now that the update is done, we can disable site maintenance if it was
// previously turned off.