diff options
author | Thomas Müller <thomas.mueller@tmit.eu> | 2013-07-11 00:04:43 +0200 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2013-07-11 00:04:43 +0200 |
commit | 2b2004b1a2df423455b4b3f87c755ea698703f6a (patch) | |
tree | 526759b03b8b1933838e95e741e8c5d9d4e6f96d /core | |
parent | 5e29f7d3246f748cc90e472711664e65c0e573f2 (diff) | |
download | nextcloud-server-2b2004b1a2df423455b4b3f87c755ea698703f6a.tar.gz nextcloud-server-2b2004b1a2df423455b4b3f87c755ea698703f6a.zip |
missing file
Diffstat (limited to 'core')
-rw-r--r-- | core/ajax/update.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/core/ajax/update.php b/core/ajax/update.php index 0b1c9386282..6aa062ef9da 100644 --- a/core/ajax/update.php +++ b/core/ajax/update.php @@ -5,11 +5,13 @@ require_once '../../lib/base.php'; if (OC::checkUpgrade(false)) { \OC_DB::enableCaching(false); + + // initialize the event source before we enter maintenance mode because CSRF protection can terminate the script + $updateEventSource = new OC_EventSource(); OC_Config::setValue('maintenance', true); $installedVersion = OC_Config::getValue('version', '0.0.0'); $currentVersion = implode('.', OC_Util::getVersion()); OC_Log::write('core', 'starting upgrade from ' . $installedVersion . ' to ' . $currentVersion, OC_Log::WARN); - $updateEventSource = new OC_EventSource(); $watcher = new UpdateWatcher($updateEventSource); OC_Hook::connect('update', 'success', $watcher, 'success'); OC_Hook::connect('update', 'error', $watcher, 'error'); |